Complete the code to include the standard input-output header.
#include [1] int main() { printf("Hello, world!\n"); return 0; }
The <stdio.h> header is required for the printf function.
Complete the command to compile a C file named program.c using gcc.
gcc [1] -o program-o option with the source file.The source file to compile is program.c. The -o option specifies the output file name.
Fix the error in the compilation command to generate only the object file.
gcc -o program.o [1] program.c-o before -c incorrectly.-c option when only compiling.The -c option tells gcc to compile only and not link. It should come before the source file.
Fill both blanks to complete the compilation stages in order.
gcc -E [1] -o [2]
.o or assembly file .s as output for preprocessing.The -E option runs the preprocessor on program.c and outputs the result to program.i.
Fill all three blanks to complete the compilation pipeline: preprocessing, compiling, and assembling.
gcc -E [1] -o [2] gcc -S [2] -o [3]
.o instead of assembly .s for the compile output.First, preprocessing program.c creates program.i. Then compiling program.i creates assembly program.s.