Please answer the following exercise 2a thru d in C program
Please answer the following exercise 2a thru d in C program only please thank you.
Write a declaration to score the string \"This is a test\" into an array named strtest. Include the declaration in a program to display the message using the following loop; for(i = 0; iSolution
Declare.c
#include <stdio.h>
int main()
{
char strtest[14] =\"This is a test\";
for(int i=0; i<=14;i++){
printf(\"%c\", strtest[i]);
}
return 0;
}
Output:
This is a test
