GoConqr has a new look! Let us know what you think.

Quiz

OS First Test Review

sosa_savannah 200 questions

Take the quiz

This quiz has question types that open in the usual player.

Questions in this quiz (200)

  1. 1Many of the statements in "C" are similar to those in "Java" since
    1. AC is based on the design of Java.
    2. BC is a design ancestor of C++ and Java.
    3. CAll programming languages use the same
      style of statements.
    4. DBoth C and Java share Eiffel as a common design ancestor.

    5. ENone of the above
  2. 2C has primitive types that are built into the language, but which of the following are not primitive types in C?
    1. Abool
    2. Bstring
    3. Cint
    4. Dchar
    5. ENone of the above
  3. 3Whenever a boolean type result is required in C (e.g., in
    an "if" statement),
    1. AAny non-zero value represents false.
    2. BOnly the zero value represents false.
    3. COnly one value represents true.
    4. DAny non-zero value represents true.
    5. ENone of the above
  4. 4In C, "&&" and "||" are short-circuit boolean operators just like in
    Java, while the "&" and "|" operators in C
    1. APerform full boolean evaluation.
    2. BAre undefined.
    3. CAre synonyms for "&&" and "||".
    4. DPerform the bitwise-and and bitwise-or functions.
    5. ENone of the above
  5. 5The "!" operator in C is used to perform
    1. ALogical negation (e.g., turn "true" into "false").
    2. BNumeric negation (e.g., turn "-3" into "3").
    3. CNumeric inversion (e.g., turn "5" into "1/5").
    4. DArray reversal (reversing the items within an array).
    5. ENone of the above
  6. 6The assignment operator (=) in C
    1. Aworks exactly like assignment in Java.
    2. Bcannot be used in boolean expressions.
    3. Ccannot be used in arithmetic expressio
    4. Dreturns the value assigned as its value.
    5. ENone of the above
  7. 7Which pairs of operators can be easy to confuse but difficult to notice
    and debug because they can often (though not always) yield the same
    results?
    1. A+ and ++
    2. B= and ==
    3. C& and &&
    4. D| and ||
    5. ENone of the above
  8. 8This example of a pre-increment operator, "x = 12; array[++x] = 3;",
    assigns
    1. A"array[12]" the value of 3
    2. B"array[13]" the value of 3
    3. C"array[12]" the value of 4
    4. D"array[13]" the value of 4
    5. ENone of the above
  9. 9This example of a compound assignment, "x = 12; array[x += 2] = 5;",
    1. Ais not allowed.
    2. Bassigns "array[12]" the value of 5
    3. Cassigns "array[14]" the value of 5
    4. Dassigns "x" the value of 7
    5. ENone of the above
  10. 10Which of the following are not used for
    either input or output in C?
    1. Ascanf
    2. Bgetc
    3. Cprintf
    4. Dfprintf
    5. ENone of the above

Information

Description
Midterm review
Language
English
Views
50
Tags
operatingsystemsreview
Rating
No ratings yet
Rate this quiz
Rate this quiz

More on C Programming Basics

Feedback

What is it about?

What do you think of the new look?

How do you like it?