C - Basics and Execution EnvironmentWhich of the following commands runs the preprocessor only in GCC?Agcc -o file file.cBgcc -c file.cCgcc -S file.cDgcc -E file.cCheck Answer
Step-by-Step SolutionSolution:Step 1: Identify GCC flags for compilation stepsThe flag '-E' tells GCC to run only the preprocessor and output the result.Step 2: Understand other flags'-c' compiles to object code, '-S' compiles to assembly, and '-o' specifies output file name.Final Answer:gcc -E file.c -> Option DQuick Check:Preprocessor only = gcc -E [OK]Quick Trick: Use gcc -E to run only the preprocessor [OK]Common Mistakes:Confusing -E with -c or -SUsing -o without understanding its purposeAssuming -c runs the preprocessor only
Master "Basics and Execution Environment" in C9 interactive learning modes - each teaches the same concept differentlyLearnWhyDeepVisualTryChallengeProjectRecallTime
More C Quizzes Conditional Statements - Switch vs if comparison - Quiz 11easy Conditional Statements - If–else statement - Quiz 2easy Conditional Statements - If–else statement - Quiz 9hard Conditional Statements - Nested conditional statements - Quiz 13medium Input and Output - Format specifiers - Quiz 9hard Loop Control Statements - Why loop control is required - Quiz 8hard Loops - Why loops are needed - Quiz 8hard Loops - Loop execution flow - Quiz 3easy Loops - Do–while loop - Quiz 11easy Variables and Data Types - Type modifiers - Quiz 9hard