Java program to print the upper case to lower case alphabets

Java program to print the upper case to lower case alphabets. Java software to convert uppercase to lowercase letters. In Java programs, this program can convert or shift uppercase to lowercase. In contrast to capital letters, small letters are used (upper case). In contrast to small letters, capital letters are used (lower case).

import java.util.Scanner;
public class Main
{
public static void main(String[] input)
{
char ch;
int temp;
Scanner scan = new Scanner(System.in);
System.out.print("Enter a single Character in Uppercase ");
ch = scan.next().charAt(0);
temp = (int) ch;
temp = temp + 32;
ch = (char) temp;
System.out.print("Character in Lowercase = " + ch);
}
}

 

Output:

Enter a single Character in Uppercase G Character in Lowercase = g

What is Upper case letters

Uppercase letters (also known as capital letters) are letters that indicate the start of a sentence or the commencement of a proper noun. Uppercase letters are used to start sentences and for proper nouns as well. All letters that do not begin sentences are lowercase letters.

What is Lower case letters

Small letters are referred to as lowercase, as opposed to capital letters. The word yes, for example, is written entirely in lowercase letters, whereas the word YES is written entirely in uppercase letters.