0
#include <stdio.h> int main() { char a = getchar(); printf("You entered: %c", a); return 0; }
In this code output I can enter multiple words and multiple character but in output it can display only my first character not display other single chatracter why??
1 Odpowiedź
+ 3
Char only store one character..
Use char array to store more characters
Also use gets function to get a block of character..
Char a[30]
Printf("enter a line");
gets(a);
puts(a)
Puts() use for print block of character..
Hope you understand..
Thanks