ASCII value of a to z
In the vast expanse of programming, where codes converge to weave intricate algorithms and applications, lies the endeavor to unravel the enigmatic realm of ASCII values. In the realm of Java, a programming language renowned for its versatility, we embark upon a journey to decode and unveil the ASCII values that lie concealed beneath the surface of seemingly mundane characters. The quest at hand: to print the entire spectrum of ASCII values from 'a' to 'z'.
Source code of Program
public class ASCII
{
public static void main(String ar[])
{
int i;
for(i=97;i<=122;i++)
{
char a=(char)i;
System.out.println(a+"="+i);
}
}
}
As we embark on deciphering this Java program, the scene is set with the establishment of the 'Print ASCII Values' class. Within the hallowed halls of the 'main' method, the stage is illuminated for the initiation of our ASCII odyssey.
Two sentinel characters are introduced to encapsulate our spectrum: 'a', the starting point, and 'z', the destination. With the framework in place, a proclamation is made, heralding the impending revelation of ASCII values.
The heart of our quest resides within a for loop, where a character 'ch' commences its journey from 'a'. As the journey progresses, 'ch' metamorphoses, traversing the alphabetic tapestry until it encounters 'z'. During each iteration, the veil of ambiguity shrouding the ASCII value is lifted, and 'ch' undergoes a transformation into an integer, an embodiment of its hidden numeric identity.
In a grand flourish, the culmination of each iteration unveils 'ch' in its original form, accompanied by the revelation of its ASCII value. With each iteration, the symphony of characters unfolds, and the array of integers cascades in a rhythmic parade of numerical revelations.
Thus, dear programmer, as you harness the power of Java to traverse the terrain of ASCII values, remember that beneath the surface of letters lies a numeric tale waiting to be told. The Java program provided is your key to unlocking this arcane realm, where characters and numbers intertwine in a dance of revelation and understanding.
![]() |
| Output Screen |

0 Comments