declare a string variable in c code example
Example 1: how to create a string in c
char greeting[6] = {'H', 'e', 'l', 'l', 'o', '\0'};
char greeting[] = "Hello";
Example 2: declare variable in c
int i, j, k;
char c, ch;
float f, salary;
double d;
Example 3: declare string in c
char string[20];