Following example shows how to convert a string to lower case.
Sample Program
package com.javatutorialcorner.javastring;
public class ToLowerCase {
public static void main(String[] args) {
String input = "Java tutorials corner contains tutorials for Java programmers day to day needs tutorials like Java, Spring, Hibernate, String, JSON, Jackson, GSON, XML parsing, Web Service, SOAP Web Service, RESTful Web Service";
String lowerCase = input.toLowerCase();
System.out.println("Input String : " + input);
System.out.println("Lower Case case String : " + lowerCase);
}
}
Output
The above code will produce the following output
Input String : Java tutorials corner contains tutorials for Java programmers day to day needs tutorials like Java, Spring, Hibernate, String, JSON, Jackson, GSON, XML parsing, Web Service, SOAP Web Service, RESTful Web Service
Lower Case case String : java tutorials corner contains tutorials for java programmers day to day needs tutorials like java, spring, hibernate, string, json, jackson, gson, xml parsing, web service, soap web service, restful web service
0 comments:
Post a Comment