Example For toLowerCase() method in java

Example For toLowerCase() method in java


Posted in : Core Java Posted on : October 1, 2010 at 3:25 PM Comments : [ 0 ]

We will discuss about the toLowerCase() method to convert the character in to lower case.

Example For toLowerCase() method in java

In this example, We will discuss about the toLowerCase() method of the character class. This method is used to convert uppercase character in to lower case. This method converts the argument to lower case using case mapping info of the Unicode data File. This method returns right value for a range of characters.

Example: CharacterToLowerCase.java

package com.devmanuals;

public class CharacterToLowerCase {

	public static void main(String[] args) {
		System.out.print("The Lower Case of R is= ");
		System.out.println(Character.toLowerCase('R'));
		System.out.print("The Lower Case of K is= ");
		System.out.println(Character.toLowerCase('K'));
		System.out.print("The Lower Case of M is= ");
		System.out.println(Character.toLowerCase('M'));

	}

}

Output:

The Lower Case of  R  is= r

The Lower Case of  K  is= k

The Lower Case of  M  is= m

Download This Example.

Go to Topic «PreviousHomeNext»

Your Comment:


Your Name (*) :
Your Email :
Subject (*):
Your Comment (*):
  Reload Image
 
 

 
Tutorial Topics