Android examples for java.lang:String Contains
is String a Alpha String
//package com.java2s; public class Main { public static boolean isAlphaString(String s) { boolean b = true; for (int i = 0; i < s.length(); i++) { if (!isAlpha(s.charAt(i))) { b = false;// ww w . jav a 2 s. c o m break; } } return b; } public static boolean isAlpha(char c) { return (c >= 'A' && c <= 'Z') || (c >= 'a' && c <= 'z'); } }