Chapter 4: Variables and Arithmetic Operations
MULTIPLE RESPONSE
Modified Multiple Choice
a. |
Comparison |
c. |
Addition |
b. |
Division |
d. |
Multiplication |
ANS: B, C, D PTS: 1 REF: 196
a. |
a place where data is stored |
c. |
defined in the coding of the program |
b. |
a named location in RAM |
d. |
a location in memory |
ANS: A, B, C, D PTS: 1 REF: 213|225
a. |
floating point number |
c. |
huge positive number |
b. |
very small negative number |
d. |
value to the right of the decimal point |
ANS: A, B, C, D PTS: 1 REF: 221
a. |
dollar amounts |
c. |
large numbers |
b. |
very precise decimal numbers |
d. |
numbers accurate to 280 digits |
ANS: A, B, C PTS: 1 REF: 221
a. |
letter |
c. |
punctuation symbol |
b. |
very large number |
d. |
symbol |
ANS: A, C, D PTS: 1 REF: 222
MODIFIED TRUE/FALSE
ANS: F, MaskedTextBox
PTS: 1 REF: 205
ANS: F, ESC
PTS: 1 REF: 211
ANS: T PTS: 1 REF: 216
ANS: F, Clear
PTS: 1 REF: 242
ANS: F, underscore
PTS: 1 REF: 246
MULTIPLE CHOICE
a. |
tbox |
c. |
txt |
b. |
txtbox |
d. |
obj |
ANS: C PTS: 1 REF: 199
a. |
label |
c. |
lab |
b. |
lbl |
d. |
txtlbl |
ANS: B PTS: 1 REF: 209
a. |
GoButton |
c. |
EnterButton |
b. |
AcceptButton |
d. |
ReturnButton |
ANS: B PTS: 1 REF: 210
a. |
ESC |
c. |
CTRL |
b. |
ENTER |
d. |
ALT |
ANS: A PTS: 1 REF: 211
a. |
Assign |
c. |
Define |
b. |
Declare |
d. |
Dim |
ANS: D PTS: 1 REF: 213
a. |
As Char |
c. |
As String |
b. |
As Char Type |
d. |
As String Type |
ANS: C PTS: 1 REF: 213
a. |
keyword Set |
c. |
equal sign (=) |
b. |
ampersand (&) |
d. |
keyword Assign |
ANS: C PTS: 1 REF: 214
a. |
blue squiggly underline |
c. |
red squiggly underline |
b. |
green squiggly underline |
d. |
yellow squiggly underline |
ANS: B PTS: 1 REF: 216
a. |
string |
c. |
character |
b. |
numeric |
d. |
either A or B |
ANS: B PTS: 1 REF: 219
a. |
Decimal |
c. |
Integer |
b. |
Double |
d. |
Single |
ANS: C PTS: 1 REF: 220
a. |
2 |
c. |
8 |
b. |
4 |
d. |
16 |
ANS: A PTS: 1 REF: 222
a. |
Boolean |
c. |
Integer |
b. |
Decimal |
d. |
Single |
ANS: A PTS: 1 REF: 222
a. |
Boolean |
c. |
Decimal |
b. |
Char |
d. |
Integer |
ANS: B PTS: 1 REF: 222
a. |
chr |
c. |
str |
b. |
wrd |
d. |
txt |
ANS: C PTS: 1 REF: 224
a. |
num |
c. |
nbr |
b. |
dec |
d. |
int |
ANS: D PTS: 1 REF: 224
a. |
dec |
c. |
num |
b. |
dml |
d. |
int |
ANS: A PTS: 1 REF: 224
a. |
str |
c. |
txt |
b. |
chr |
d. |
wrd |
ANS: B PTS: 1 REF: 224
a. |
tru |
c. |
bln |
b. |
tfl |
d. |
trf |
ANS: C PTS: 1 REF: 224
a. |
Boolean |
c. |
Single |
b. |
Char |
d. |
Date |
ANS: D PTS: 1 REF: 224
a. |
sng |
c. |
num |
b. |
sin |
d. |
sge |
ANS: A PTS: 1 REF: 224
a. |
dbl |
c. |
dou |
b. |
dub |
d. |
dob |
ANS: A PTS: 1 REF: 224
a. |
Single |
c. |
Double |
b. |
Integer |
d. |
Decimal |
ANS: D PTS: 1 REF: 225
a. |
Char |
c. |
Integer |
b. |
Short |
d. |
Decimal |
ANS: A PTS: 1 REF: 225
a. |
range |
c. |
scope |
b. |
lifetime |
d. |
scale |
ANS: C PTS: 1 REF: 227
a. |
lifetime |
c. |
range |
b. |
scope |
d. |
duration |
ANS: A PTS: 1 REF: 228
a. |
Manual Conversion On |
c. |
Manual Conversion Off |
b. |
Option Strict Off |
d. |
Option Strict On |
ANS: D PTS: 1 REF: 231
a. |
integer |
c. |
modular |
b. |
decimal |
d. |
linear |
ANS: A PTS: 1 REF: 233
a. |
* |
c. |
~ |
b. |
^ |
d. |
\ |
ANS: B PTS: 1 REF: 233
a. |
modular |
c. |
linear |
b. |
integer |
d. |
decimal |
ANS: B PTS: 1 REF: 236 | 237
a. |
Fixed (F) |
c. |
Currency (C) |
b. |
Number (N) |
d. |
General ( G) |
ANS: B PTS: 1 REF: 241
a. |
Fixed (F) |
c. |
General (G) |
b. |
Number (N) |
d. |
Currency (C) |
ANS: A PTS: 1 REF: 241
a. |
Fixed (F) |
c. |
General (G) |
b. |
Number (N) |
d. |
Currency (C) |
ANS: D PTS: 1 REF: 241
a. |
Fixed (F) |
c. |
General (G) |
b. |
Number (N) |
d. |
Currency (C) |
ANS: C PTS: 1 REF: 241
a. |
scope |
c. |
visibility |
b. |
focus |
d. |
precision |
ANS: B PTS: 1 REF: 244
a. |
& |
c. |
@ |
b. |
# |
d. |
+ |
ANS: A PTS: 1 REF: 246
a. |
addition |
c. |
combination |
b. |
alignment |
d. |
concatenation |
ANS: D PTS: 1 REF: 246
a. |
Style |
c. |
Format |
b. |
Substance |
d. |
Setting |
ANS: C PTS: 1 REF: 248
a. |
Excessive input |
c. |
Stack |
b. |
MaxSize |
d. |
Overflow |
ANS: D PTS: 1 REF: 250
a. |
Excessive input |
c. |
Stack |
b. |
MaxSize |
d. |
Overflow |
ANS: D PTS: 1 REF: 250
a. |
Divide by Zero |
c. |
Zero error |
b. |
Zero denominator |
d. |
Division Error |
ANS: A PTS: 1 REF: 250
TRUE/FALSE
ANS: F PTS: 1 REF: 197
ANS: T PTS: 1 REF: 199
ANS: T PTS: 1 REF: 201
ANS: F PTS: 1 REF: 204
ANS: T PTS: 1 REF: 207
ANS: F PTS: 1 REF: 213
ANS: F PTS: 1 REF: 213
ANS: T PTS: 1 REF: 214
ANS: T PTS: 1 REF: 219
ANS: F PTS: 1 REF: 219
ANS: T PTS: 1 REF: 219
ANS: F PTS: 1 REF: 222
ANS: F PTS: 1 REF: 223
ANS: F PTS: 1 REF: 223
ANS: F PTS: 1 REF: 224
ANS: T PTS: 1 REF: 225
ANS: T PTS: 1 REF: 227
ANS: F PTS: 1 REF: 228
ANS: F PTS: 1 REF: 229
ANS: F PTS: 1 REF: 229
ANS: F PTS: 1 REF: 231
ANS: F PTS: 1 REF: 238
ANS: F PTS: 1 REF: 238
ANS: F PTS: 1 REF: 240
ANS: T PTS: 1 REF: 250
COMPLETION
ANS: TextBox
PTS: 1 REF: 197
ANS: TextAlign
PTS: 1 REF: 202
ANS: MultiLine
PTS: 1 REF: 204
ANS: mask
PTS: 1 REF: 205
ANS: MaskedTextBox
PTS: 1 REF: 205
ANS:
ENTER
enter
return
PTS: 1 REF: 210
ANS: variable
PTS: 1 REF: 213
ANS:
copied
assigned
PTS: 1 REF: 214
ANS:
Integer
PTS: 1 REF: 220
ANS: constant
PTS: 1 REF: 226
ANS: Sub
PTS: 1 REF: 229
ANS: argument
PTS: 1 REF: 229
ANS:
function
Function procedure
PTS: 1 REF: 229
ANS: class
PTS: 1 REF: 229
ANS: multiplication
PTS: 1 REF: 233
ANS: exponentiation
PTS: 1 REF: 233
ANS: ToString
PTS: 1 REF: 239
ANS: precision
PTS: 1 REF: 241
ANS: Clear
PTS: 1 REF: 242
ANS: concatenation
PTS: 1 REF: 246
MATCHING
Identify the letter of the choice that best matches the phrase or definition.
a. |
program |
f. |
method |
b. |
ToString |
g. |
class |
c. |
constant |
h. |
procedure |
d. |
precision specifier |
i. |
local |
e. |
function |
j. |
literal |
ESSAY
ANS:
The name must begin with a letter or an underline symbol (_). The name can contain letters, numbers, or the underline symbol. It cannot contain spaces or other special characters. No Visual Basic reserved words (words that appear in blue in the code editing window) can be used for variable names. Good programming practice dictates that the variable names you use should reflect the actual values to be placed in the variable. That way, anyone reading the program code can easily understand the use of the variable. For example, a good variable name for a string variable that will contain an employee’s last name would be strEmployeeLastName. Names you should not use include strXXX, strLN, strEmp, or strName. Each of these names is imprecise and potentially misleading. You should consider the people who will be reading your code when you name the variables in your program. Your goal must be to make the task of reading your code as clear and easy as possible.
PTS: 1 REF: 213|214 TOP: Critical Thinking
ANS:
Visual Basic 2010 now allows you to omit the data type without error, so this line of code does not generate an error because the compiler infers that the value of the intValue is an Integer data type. This is called type inference. While you are learning beginning programming, however, it is best to use the data types to understand the changes as you convert one data type to another.
PTS: 1 REF: 220 TOP: Critical Thinking
ANS:
PTS: 1 REF: 226 TOP: Critical Thinking
CASE
Critical Thinking Questions
Case 4-1
Brian is trying his best to understand the concept of variable scope, so he calls his friend Molly for guidance.
a. The variable strNumberOfSongs has no scope. |
c. The variable strNumberOfSongs was not declared correctly. |
b. The variable strNumberOfSongs is a local variable. |
d. The variable strNumberOfSongs is a global variable. |
ANS:
B
PTS: 1 REF: 227
a. It is “alive” for the entire duration of the program. |
c. It is “alive” until the procedure is called by the larger program. |
b. It is “alive” with the same contents during all executions of the procedure by the program. |
d. It is “alive” from the time the procedure begins executing until the procedure ends. |
ANS:
D
PTS: 1 REF: 228
Critical Thinking Questions
Case 4-2
The arithmetic operators in your program are not behaving the way you think they should be, so you decide to brush up on your operators and the hierarchy of operations.
a. 2 |
c. 2.4 |
b. 2.6 |
d. 3 |
ANS:
A
PTS: 1 REF: 228
a. exponentiation, multiplication, integer division, MOD, addition |
b. multiplication, exponentiation, MOD, integer division, addition |
c. integer division, multiplication, exponentiation, MOD, addition |
d. multiplication, integer division, exponentiation, MOD, addition |
ANS:
A
PTS: 1 REF: 238
hihi
Earn back money you have spent on downloaded sample
To export a reference to this article please select a referencing stye below.
Assignment Hippo (2021) . Retrive from http://www.assignmenthippo.com/sample-assignment/variables-and-arithmetic-operations-mcqs
"." Assignment Hippo ,2021, http://www.assignmenthippo.com/sample-assignment/variables-and-arithmetic-operations-mcqs
Assignment Hippo (2021) . Available from: http://www.assignmenthippo.com/sample-assignment/variables-and-arithmetic-operations-mcqs
[Accessed 11/04/2021].
Assignment Hippo . ''(Assignment Hippo,2021) http://www.assignmenthippo.com/sample-assignment/variables-and-arithmetic-operations-mcqs accessed 11/04/2021.
Want to order fresh copy of the Sample Template Answers? online or do you need the old solutions for Sample Template, contact our customer support or talk to us to get the answers of it.
Our motto is deliver assignment on Time. Our Expert writers deliver quality assignments to the students.
Get reliable and unique assignments by using our 100% plagiarism-free.
Get connected 24*7 with our Live Chat support executives to receive instant solutions for your assignment.
Get Help with all the subjects like: Programming, Accounting, Finance, Engineering, Law and Marketing.
Get premium service at a pocket-friendly rate at AssignmentHippo
I was struggling so hard to complete my marketing assignment on brand development when I decided to finally reach to the experts of this portal. They certainly deliver perfect consistency and the desired format. The content prepared by the experts of this platform was simply amazing. I definitely owe my grades to them.
Get instant assignment help