No one has voted on any posts yet. Votes from other community members are used to determine a member's reputation amongst their peers.
2 Posted Topics
#include<stdio.h> #include<stdlib.h> int main() { int i,j; int ascii_value; char c; FILE *plain; plain=fopen("xx.dat","r"); while((c=getc(plain))!=EOF) { ascii_value=c; printf("%d %c\n",ascii_value,c); printf("~~~~~~~~~~~~~~~~~~~~\n"); } fclose(plain); return 0; } the file xx.dat is 12sdfsldkfj MY output is 49 1 ~~~~~~~~~~~~~~~~~~~~ 50 2 ~~~~~~~~~~~~~~~~~~~~ 115 s ~~~~~~~~~~~~~~~~~~~~ 100 d ~~~~~~~~~~~~~~~~~~~~ 102 f ~~~~~~~~~~~~~~~~~~~~ 115 s … | |
#include<stdio.h> #include<stdlib.h> int main() { int i,j; int ascii_value; char c; FILE *plain; plain=fopen("xx.dat","r"); while((c=getc(plain))!=EOF) { ascii_value=c; printf("%d %c\n",ascii_value,c); printf("~~~~~~~~~~~~~~~~~~~~\n"); } fclose(plain); return 0; } the file xx.dat is 12sdfsldkfj MY output is 49 1 ~~~~~~~~~~~~~~~~~~~~ 50 2 ~~~~~~~~~~~~~~~~~~~~ 115 s ~~~~~~~~~~~~~~~~~~~~ 100 d ~~~~~~~~~~~~~~~~~~~~ 102 f ~~~~~~~~~~~~~~~~~~~~ 115 s … |
The End.