1// Java program to print alphabets using ascii values
2public class PrintAlphabetUsingAscii
3{
4 public static void main(String[] args)
5 {
6 char ch = 'B';
7 int ascii = ch;
8 int castAscii = (int) ch;
9 System.out.println("ascii value of " + ch + " is: " + ascii);
10 System.out.println("ascii value of " + ch + " is: " + castAscii);
11 }
12}