84. JAVA Program to print ASCII values from 0 to 255.
How does this program work?
- This program is used to print ASCII values of numbers from 0 to 255 using Java.
- In this program chr() function can built-in function in Java because it is used to display ASCII value of equivalent given number.
Here is the code
//To print ASCII values from 0 to 255
public class value{
public static void main(String[] args)
{
int i;
for (i = 0; i <= 255; i++)
{
System.out.println(" The ASCII value of " + (char)i + " = " + i);
}
}
}