stud
bud
Sign up
Log in
Home
Library
Explore
SAT
More
C Programming Midterm Prep Flashcards | StudBud
Explore
/
C Programming Midterm Prep
C Programming Midterm Prep
10 terms
·
StudBud Administration
·
17 plays
Intro to Programming Concepts - #C #programming through #selection and #loops.
Flashcards
10 cards
F
Practice quiz
P
Host live
L
Questions
10
Answers
1
A do-while loop is useful when we want the statements within the loop to be executed
only once
at least 20 times
at least once
never
2
Which code generates an error?
int x = 5; int y = 8;
printf("Happy);
int x = 5; y=7;
printf("Do not fall for this answer\n\n\n");
3
What is at the end of (almost) every C statement?
.
;
!
:
4
Which statement is used to loop a certain number of times with the counter built in?
switch
while
do while
for
5
Variable names must
be at least 10 characters long
start with a letter
start with a letter or a number
end with a number
6
255 is the highest decimal value represented by 8 bits.
False
True
7
The software program that translates source code into machine language.
processor
compiler
translator
assembler
8
Usually, a syntax error is much harder to find than a logic error
false
true
9
Errors identified by the compiler are called
output errors
logic errors
time of value errors
syntax errors
10
while is best used when
the number of iterations is not known
the user will enter a sentinel to stop the loop
the loop will only run once
the number of iterations is known