Monday, February 2, 2009

first charecter to upper case

public class Sample {

/**
* @param args
*/
public static void main(String[] args) {
// TODO Auto-generated method stub
String abc = "hello";
abc = Character.toUpperCase(abc.charAt(0)) + abc.substring(1);
System.out.println(abc);

}
}

No comments:

Post a Comment