Deck 3: Processing and Interactive Input

ملء الشاشة (f)
exit full mode
سؤال
In C, the assignment operator has the highest precedence of all the binary and unary arithmetic operators.
استخدم زر المسافة أو
up arrow
down arrow
لقلب البطاقة.
سؤال
The cast operator is a binary operator.
سؤال
An rvalue refers to any quantity that is valid on the right side of an assignment operator.
سؤال
The automatic conversion across an assignment operator is referred to as an implicit type conversion.
سؤال
A special type of assignment statement that is very similar to the accumulating statement is the counting statement.
سؤال
When the -- operator appears before a variable, it is called a postfix decrement operator.
سؤال
When the -- operator appears after a variable, it is called a prefix decrement operator.
سؤال
Robust programs are informally known as "bullet-proof" programs.
سؤال
The format of numbers displayed by printf() can be controlled by field width specifiers included as part of each conversion control sequence.
سؤال
C provides the programmer with the capability to define a value (that will be used throughout a program) once by equating the number to a symbolic name.
سؤال
In C, the equal sign has the same meaning as an equal sign in algebra.
سؤال
In addition to being a constant, the operand to the right of the equal sign in an assignment statement can be a variable or any valid C expression.
سؤال
The expression amount + 1892 = 1000 + 10 * 5 is valid in C.
سؤال
Data type conversions take place across assignment operators.
سؤال
=+ is a valid C operator.
سؤال
In C, log(x) yields the common log of x (base 10).
سؤال
A function can be regarded as a "black box," where the arguments constitute the inputs to the box.
سؤال
The argument to the sqrt function must be an integer value.
سؤال
The arguments passed to a mathematical function must be single constants.
سؤال
The returned value of a function may not be used as an argument to another function.
سؤال
The control string passed to scanf() typically consists of conversion control sequences only.
سؤال
The scanf() function tests the data type of the values being entered.
سؤال
The fflush() function flushes the input buffer of any remaining characters.
سؤال
The order of the format modifiers in printf() is not critical.
سؤال
The statement variable = variable + 1; is equivalent to variable++;.
سؤال
The cast operator has the syntax ____.

A)(dataType expression)
B)(expression dataType)
C)(dataType) expression
D)expression (dataType)
سؤال
In C, the ____ symbol is called the assignment operator.

A)=
B)++
C)--
D)()
سؤال
The term ____ refers to any quantity that is valid on the left side of an assignment operator.

A)leftv
B)lval
C)variable
D)lvalue
سؤال
A previously stored number, if it has not been initialized to a specific and known value, is frequently referred to as a ____.

A)garbage value
B)literal
C)bogus value
D)buffer
سؤال
When the ++ operator appears after a variable, it is called a ____ increment operator.

A)basic
B)standard
C)postfix
D)prefix
سؤال
A(n) ____ is a message that tells the person at the screen what should be typed.

A)prompt
B)input statement
C)scanf
D)printf
سؤال
On most computer systems characters read by the keyboard are stored in a temporary holding area called a ____ immediately after they are pressed.

A)register
B)buffer
C)stack
D)RAM
سؤال
Programs that detect and respond effectively to unexpected user input are formally referred to as ____ programs.

A)standard
B)robust
C)cost-effective
D)abstract
سؤال
Literal values that appear many times in the same program are referred to by programmers as ____ numbers.

A)symbolic
B)magic
C)constant
D)literal
سؤال
____ statements are also called equivalence statements.

A)Assignment
B)Prompt
C)#include
D)#define
سؤال
____ is a valid statement in C.

A)a = 10 = c = 25;
B)a = b = c = 25;
C)2 = b;
D)a - 1 = c;
سؤال
Which of the following statements about rvalues and lvalues is NOT true?

A)Any expression that yields a value can be an rvalue.
B)A variable declared for an array cannot be an rvalue, but individual array variables can be.
C)A variable declared for an array can be an lvalue.
D)Individual numbers can only be an rvalue.
سؤال
The statement ____ shows an implicit conversion.

A)int total = (int) sum;
B)double avg = 0.0;
C)float price = 9.90f;
D)int answer = 2.745;
سؤال
The expression sum = sum + 10 can be written as ____.

A)sum =+ 10
B)sum += 10
C)sum = sum ++ 10
D)sum ++ 10
سؤال
The expression price *= rate + 1 is equivalent to the expression ____.

A)price = price (rate + 1)
B)price = price rate + 1
C)price = (price rate) + 1
D)price = price ^ (rate + 1)
سؤال
The C function ____ yields the result of a value raised to the power of another value.

A)pow
B)exp
C)abs
D)sqrt
سؤال
To access the mathematical functions such as log and sqrt, you must include the following preprocessor statement in your program: ____.

A)#define
B)#include
C)#define
D)#include
سؤال
If you are using a Unix or Linux operating system, you must include the ____ option when compiling a C program that uses the mathematical functions like log and sqrt.

A)-lm
B)-l math.h
C)-math
D)-lib = math
سؤال
The ____ function requires a control string as the first argument inside the function name parentheses.

A)sqrt()
B)pow()
C)scanf()
D)log()
سؤال
Formatted floating-point numbers require ____ field width specifier(s).

A)one
B)two
C)three
D)four
سؤال
Format modifiers, if used, must always be placed immediately after the ____ symbol.

A)!
B)=
C)%
D))
سؤال
The conversion control sequence ____ would cause an integer number to both display its sign and be left-justified in a field width of 10 spaces.

A) %-+10d
B) %-10d
C) %+10d
D) %*10d
سؤال
The ____ sign is a signal to a C preprocessor.

A) !
B) &
C) ;
D) #
فتح الحزمة
قم بالتسجيل لفتح البطاقات في هذه المجموعة!
Unlock Deck
Unlock Deck
1/48
auto play flashcards
العب
simple tutorial
ملء الشاشة (f)
exit full mode
Deck 3: Processing and Interactive Input
1
In C, the assignment operator has the highest precedence of all the binary and unary arithmetic operators.
False
2
The cast operator is a binary operator.
False
3
An rvalue refers to any quantity that is valid on the right side of an assignment operator.
True
4
The automatic conversion across an assignment operator is referred to as an implicit type conversion.
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 48 في هذه المجموعة.
فتح الحزمة
k this deck
5
A special type of assignment statement that is very similar to the accumulating statement is the counting statement.
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 48 في هذه المجموعة.
فتح الحزمة
k this deck
6
When the -- operator appears before a variable, it is called a postfix decrement operator.
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 48 في هذه المجموعة.
فتح الحزمة
k this deck
7
When the -- operator appears after a variable, it is called a prefix decrement operator.
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 48 في هذه المجموعة.
فتح الحزمة
k this deck
8
Robust programs are informally known as "bullet-proof" programs.
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 48 في هذه المجموعة.
فتح الحزمة
k this deck
9
The format of numbers displayed by printf() can be controlled by field width specifiers included as part of each conversion control sequence.
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 48 في هذه المجموعة.
فتح الحزمة
k this deck
10
C provides the programmer with the capability to define a value (that will be used throughout a program) once by equating the number to a symbolic name.
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 48 في هذه المجموعة.
فتح الحزمة
k this deck
11
In C, the equal sign has the same meaning as an equal sign in algebra.
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 48 في هذه المجموعة.
فتح الحزمة
k this deck
12
In addition to being a constant, the operand to the right of the equal sign in an assignment statement can be a variable or any valid C expression.
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 48 في هذه المجموعة.
فتح الحزمة
k this deck
13
The expression amount + 1892 = 1000 + 10 * 5 is valid in C.
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 48 في هذه المجموعة.
فتح الحزمة
k this deck
14
Data type conversions take place across assignment operators.
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 48 في هذه المجموعة.
فتح الحزمة
k this deck
15
=+ is a valid C operator.
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 48 في هذه المجموعة.
فتح الحزمة
k this deck
16
In C, log(x) yields the common log of x (base 10).
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 48 في هذه المجموعة.
فتح الحزمة
k this deck
17
A function can be regarded as a "black box," where the arguments constitute the inputs to the box.
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 48 في هذه المجموعة.
فتح الحزمة
k this deck
18
The argument to the sqrt function must be an integer value.
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 48 في هذه المجموعة.
فتح الحزمة
k this deck
19
The arguments passed to a mathematical function must be single constants.
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 48 في هذه المجموعة.
فتح الحزمة
k this deck
20
The returned value of a function may not be used as an argument to another function.
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 48 في هذه المجموعة.
فتح الحزمة
k this deck
21
The control string passed to scanf() typically consists of conversion control sequences only.
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 48 في هذه المجموعة.
فتح الحزمة
k this deck
22
The scanf() function tests the data type of the values being entered.
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 48 في هذه المجموعة.
فتح الحزمة
k this deck
23
The fflush() function flushes the input buffer of any remaining characters.
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 48 في هذه المجموعة.
فتح الحزمة
k this deck
24
The order of the format modifiers in printf() is not critical.
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 48 في هذه المجموعة.
فتح الحزمة
k this deck
25
The statement variable = variable + 1; is equivalent to variable++;.
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 48 في هذه المجموعة.
فتح الحزمة
k this deck
26
The cast operator has the syntax ____.

A)(dataType expression)
B)(expression dataType)
C)(dataType) expression
D)expression (dataType)
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 48 في هذه المجموعة.
فتح الحزمة
k this deck
27
In C, the ____ symbol is called the assignment operator.

A)=
B)++
C)--
D)()
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 48 في هذه المجموعة.
فتح الحزمة
k this deck
28
The term ____ refers to any quantity that is valid on the left side of an assignment operator.

A)leftv
B)lval
C)variable
D)lvalue
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 48 في هذه المجموعة.
فتح الحزمة
k this deck
29
A previously stored number, if it has not been initialized to a specific and known value, is frequently referred to as a ____.

A)garbage value
B)literal
C)bogus value
D)buffer
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 48 في هذه المجموعة.
فتح الحزمة
k this deck
30
When the ++ operator appears after a variable, it is called a ____ increment operator.

A)basic
B)standard
C)postfix
D)prefix
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 48 في هذه المجموعة.
فتح الحزمة
k this deck
31
A(n) ____ is a message that tells the person at the screen what should be typed.

A)prompt
B)input statement
C)scanf
D)printf
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 48 في هذه المجموعة.
فتح الحزمة
k this deck
32
On most computer systems characters read by the keyboard are stored in a temporary holding area called a ____ immediately after they are pressed.

A)register
B)buffer
C)stack
D)RAM
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 48 في هذه المجموعة.
فتح الحزمة
k this deck
33
Programs that detect and respond effectively to unexpected user input are formally referred to as ____ programs.

A)standard
B)robust
C)cost-effective
D)abstract
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 48 في هذه المجموعة.
فتح الحزمة
k this deck
34
Literal values that appear many times in the same program are referred to by programmers as ____ numbers.

A)symbolic
B)magic
C)constant
D)literal
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 48 في هذه المجموعة.
فتح الحزمة
k this deck
35
____ statements are also called equivalence statements.

A)Assignment
B)Prompt
C)#include
D)#define
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 48 في هذه المجموعة.
فتح الحزمة
k this deck
36
____ is a valid statement in C.

A)a = 10 = c = 25;
B)a = b = c = 25;
C)2 = b;
D)a - 1 = c;
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 48 في هذه المجموعة.
فتح الحزمة
k this deck
37
Which of the following statements about rvalues and lvalues is NOT true?

A)Any expression that yields a value can be an rvalue.
B)A variable declared for an array cannot be an rvalue, but individual array variables can be.
C)A variable declared for an array can be an lvalue.
D)Individual numbers can only be an rvalue.
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 48 في هذه المجموعة.
فتح الحزمة
k this deck
38
The statement ____ shows an implicit conversion.

A)int total = (int) sum;
B)double avg = 0.0;
C)float price = 9.90f;
D)int answer = 2.745;
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 48 في هذه المجموعة.
فتح الحزمة
k this deck
39
The expression sum = sum + 10 can be written as ____.

A)sum =+ 10
B)sum += 10
C)sum = sum ++ 10
D)sum ++ 10
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 48 في هذه المجموعة.
فتح الحزمة
k this deck
40
The expression price *= rate + 1 is equivalent to the expression ____.

A)price = price (rate + 1)
B)price = price rate + 1
C)price = (price rate) + 1
D)price = price ^ (rate + 1)
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 48 في هذه المجموعة.
فتح الحزمة
k this deck
41
The C function ____ yields the result of a value raised to the power of another value.

A)pow
B)exp
C)abs
D)sqrt
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 48 في هذه المجموعة.
فتح الحزمة
k this deck
42
To access the mathematical functions such as log and sqrt, you must include the following preprocessor statement in your program: ____.

A)#define
B)#include
C)#define
D)#include
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 48 في هذه المجموعة.
فتح الحزمة
k this deck
43
If you are using a Unix or Linux operating system, you must include the ____ option when compiling a C program that uses the mathematical functions like log and sqrt.

A)-lm
B)-l math.h
C)-math
D)-lib = math
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 48 في هذه المجموعة.
فتح الحزمة
k this deck
44
The ____ function requires a control string as the first argument inside the function name parentheses.

A)sqrt()
B)pow()
C)scanf()
D)log()
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 48 في هذه المجموعة.
فتح الحزمة
k this deck
45
Formatted floating-point numbers require ____ field width specifier(s).

A)one
B)two
C)three
D)four
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 48 في هذه المجموعة.
فتح الحزمة
k this deck
46
Format modifiers, if used, must always be placed immediately after the ____ symbol.

A)!
B)=
C)%
D))
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 48 في هذه المجموعة.
فتح الحزمة
k this deck
47
The conversion control sequence ____ would cause an integer number to both display its sign and be left-justified in a field width of 10 spaces.

A) %-+10d
B) %-10d
C) %+10d
D) %*10d
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 48 في هذه المجموعة.
فتح الحزمة
k this deck
48
The ____ sign is a signal to a C preprocessor.

A) !
B) &
C) ;
D) #
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 48 في هذه المجموعة.
فتح الحزمة
k this deck
locked card icon
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 48 في هذه المجموعة.