I'm very new to programming and decided to start with C. This is my first real problem where I can't figure it out for myself.
#include <stdio.h>
#include <stdlib.h>
int main()
{
char String[20];
int CharNo = 0;
//Asking the User to input some characters to use in the program
printf("Enter a few characters please:\n");
scanf("%s", String);
printf("%c\n", String[0]);
return 0;
}
I have asked the user to input a few random characters, then what I want to be able to do is print out the input string character by character on a new line. All I'm able to do by myself if print out one of the characters by itself.
Any help about this problem and my coding overall would be greatly appreciated.