Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include <stdio.h>
- main ()
- {
- char name [100], ch;
- int i=0;
- while (i<100)
- {
- if((ch=getchar())!='\n')
- {
- name[i++] = ch;
- }
- else
- {
- break;
- }
- name [i] = '\0';
- }
- printf("%s",name);
- return 0;
- }
Advertisement
Add Comment
Please, Sign In to add comment