C program to read and print name, where memory for variable should be declared at run time
This program is an example of Dynamic Memory Allocation, where maximum length of the name (number of characters) to be read at run time, program will declare memory for entered length of the name using malloc(), then program will read the name and print.
Consider the program:
Output
need an explanation for this answer? contact us directly to get an explanation for this answer