Vidyalelo
C Programming · Q153

Standard Library Functions

Programming · C Programming · question 153

Q153

What will the following C code do on compilation? void main () char com[50]; strcpy( com, "dir" ); system(com);

A.
error
B.
lists down all the files and directories in the current directory under windows machine
Answer
C.
terminates the calling process immediately
D.
calls specified function and terminates it at the end of the program

Answer: Option B

Solution

Answer: Option B
No explanation is given for this question Let's Discuss on Board