Write a program to print all the ASCII values and their equivalent characters using a while loop. The ASCII values vary from 0 to 255.

#include<stdio.h>
main()
{
int num;

printf("Printing ASCII values Table...\n\n");

num = 1;

while(num<=255)

{

printf("\nValue:%d = ASCII Character:%c", num, num); /*This change has been made as per the comment. Thank you anonymous Blog Viewer ... */

num++;
}

printf("\n\nEND\n");

}


Mistake made in this program was two variables one with int and one with char type were taken...the other being redundant.
The change has been made here on the blog, but it still remains to be changed in the file to be downloaded. Will do that soon.


The file can be downloaded at:
Download File

No comments:

Post a Comment

kiss on google ads if you are anonymous because your ip is trackable.thank you.

......from.admin