Week 2 Quiz
Sign in to Google to save your progress. Learn more
Basic Code Syntax
Preprocessor directives are statements that are executed before compilation of our actual code begins. Which of the following is regarded as a preprocessor directive?
Clear selection
Which of the following functions is the appropriate function for writing our C code in?
Clear selection
For code written in our functions, we introduce a symbol at the end of each line to allow the compiler to discern between different lines of code. Which of the following is the correct symbol?
Clear selection
What will happen to my compiled program if there are syntax errors with the source code?
Clear selection
What will happen to my compiled program if there are run-time errors with the source code?
Clear selection
On Page 17, we revisit the general pattern of an algorithm - input, compute and output. scanf and printf are functions quoted to perform input and output respectively. Which preprocessor directive (or to be more precise, the header file) is required for scanf and printf to work?
Clear selection
In scanf related statements, the "&" symbol is placed next to the variable which will take in the input. What does "&" combined with the variable name stand for?
Clear selection
In both printf and scanf related statements, format specifiers such as "%d" are used. For what data type does "%d" correspond to?
Clear selection
Image 1
Image 1
In Image 1, the specifier "%d" is used in a printf statement. What is it used for?
Clear selection
On page 11, we see the newline character being used. What does this newline character actually do?
Clear selection
Next
Clear form
Never submit passwords through Google Forms.
This content is neither created nor endorsed by Google. - Terms of Service - Privacy Policy

Does this form look suspicious? Report