sample midterm Flashcards
Method String.Format is used to _____________.
Question 1 options:
A) create constants
B) format Visual Basic statements
C) control how text is formatted
D) display the formatted text in a text box
C) control how text is formatted
The three types of control structures are sequence, selection, and __________.
Question 2 options:
A) redo
B) repeat
C) repetition
D) looping
C) repetition
If there are errors in an application, they appear in a window known as the ___________.
A) Task List
B) Error List
C) Output
D) Local
B) Error List
When a value is placed into a memory location, the value _________ the previous value in that location.
A) copies
B) adds itself to
C) replaces
D) moves
C) replaces
A(n) ________ help the user understand a control’s purpose.
A) Button
B) descriptive Label
C) TextBox
D) title bar
B) descriptive Label
A __________ is a control in which the user can enter data from a keyboard.
A) Button
B) Label
C) PictureBox
D) TextBox
D) TextBox
An example of a white space character is a ________ character.
A) Tab
B) Space
C) newline
D) All of the above
D) All of the above
Variables that store floating Point values should be declared as a(n) _____________.
A) Int
B) Integer
C) Long
D) Double
D) Double
The data type in a variable declaration is immediately preceded by keyword ___________.
A) IsA
B) Type
C) As
D) Dim
C) As
__________ is a programming language for sharing information via hyperlinked text documents on the World Wide Web.
A) HTTP
B) HTML
C) XML
D) Java
B) HTML
A _______________ is a group of one or more projects which form a program
1) a property
2) a solution
3) a visual basic file
4) a program
2) a solution
if x = 6 and y = 2 what is displayed by
txtOutput.Text = x / y + y \ x instruction in the txtOutput Text Box.
1) 3
2) 6
3) 6+2
4) 8
1) 3
Sequential execution refers to:
1) statements that execute an IF_ELSE
2) statements that execute one after another.
3) statements that execute when the program compiles
4) statements that execute outside a loop.
2) statements that execute one after another.
The += operator does what function?
1) increments the variable by the value evaluated on the right.
2) results in an error
3) adds the adjacent variable and then performs the evaluation to the right of the equals
sign.
4) decrements the variable by the value evaluated on the right.
1) increments the variable by the value evaluated on the right.
The first mathematical operator calculated in “4 - 6 mod (5 + 8 / 3 * 2)” is
1) -
2) mod
3) +
4) *
5) /
5) /
What step in the program development produces the executable code?
1) run
2) edit
3) build
4) clean
3) build
Which of the following is not an Input Device
1) Keyboard
2) Mouse
3) Printer
4) WebCam
3) Printer
1) ABSOLUTE_TEMP
2) sure&thing
3) interestRate
4) _total
2) sure&thing
which of these expressions evaluate to TRUE?
1) 5 = 18 mod 13
2) 20 <> 2.0
4) all of the above
4) all of the above
The purpose of the ALU is:
A) to store permanent data
B) to store temporary data
C) to cool the computer down and prevent overheating
D) to perform basic math logical comparisons for the computer
D) to perform basic math logical comparisons for the computer
Machine languages ______________.
A) are machine dependent.
B) are universal between all machines.
C) consist of numbers and letters
D) need to translated in order for the machine to understand commands.
A) are machine dependent.
The _________ is a collection of hardware and software associated with Internet that allows computer users to locate and view multi-media documents on almost any subject.
A) HyperText Markup Language (HTML)
B) HyperText Transfer Protocol (HTTP)
C) World Wide Web (www)
D) CERN
C) World Wide Web (www)
Which of the following is/are true about Visual Basic.
A) It’s object oriented.
B) It makes windows programming easier.
C) It’s event driven.
D) All of the above.
D) All of the above.
Part of the .NET Initiative is Microsoft’s _______ technology, which enables you to create web applications:
A) class library
B) Vitual Machine
C) XML
D) ASP.NET
D) ASP.NET
___________ are software systems that make using computers more convenient for users, application developers, and system administrators.
A) Operating Systems
B) Application programs
C) Graphical User Interface
D) Internet
A) Operating Systems
Visual Basic programs are created using Microsoft’s Visual Studio- a collection of sofware tools called a(n) __________.
A) Operating System
B) Integrated Programming Environment
C) Integrated Development Environment
D) Microsoft Foundation Class
C) Integrated Development Environment
A Textbox’s ________ property can be used to change the text that’s displayed in a Textbox.
A) Content
B) Data
C) Name
D) Text
D) Text
Data types already defined in Visual Basic, such as String and Integer, are known as ________.
A) Constant data types
B) Standard Data types
C) User defined data types
D) Primitive data types
D) Primitive data types
A binary operator has _______ operands(s).
A) One
B) two
C) zero
D) two or more
B) two
Set a Label’s ___________ property to Fixed3D to give the Label a three-dimensional appearance.
A) BorderStyle
B) BorderDepth
C) BorderShading
D) Borderperspective
A) BorderStyle
A transfer of control occurs when:
A) a program changes from input to output, or vice versa
B) a logic error occurs in a program.
C) a statement other than the next sequential one in the program executes.
D) none of the above
C) a statement other than the next sequential one in the program executes.
What does the expression x = 10 do?
A) Multiply 10 by the value of x, and stores the result in x.
B) Divide x by 10 and stores the remainder in x.
C) Divide x by 10 and stores the integer result in x.
D) Divide x by 10 and store the floating point result in x.
C) Divide x by 10 and stores the integer result in x.
The expression value *= 4 is an abbreviation for:
A) value = 4value
B) value * 4 = value
C) value * value * 4
D) value = value * 4
D) value = value * 4
Which of the following is not a debugger feature?
Incorrect Response
A) examining and setting variable values
B) locating syntax error
C) watching the values of variables and expressions
D) viewing the values of variables and expressions
B) locating syntax error
To execute a program one statement at a time without entering the code of a called method, use the debugger’s_________ command.
A) Step Over
B) Step Under
C) Step Into
D) Step Out
A) Step Over
The expression following the keywords Select Case is called the:
A) selection expression
B) variable expression
C) controlling expression
D) Case expression
C) controlling expression
Which of the following operators is typically used to ensure at least one out of multiple conditions is true?
A) Or
B) And
C) XOr
D) Not
A) Or
Identify the incorrect logical operator:
A) AndAlso
B) ElseOr
C) Xor
D) Not
B) ElseOr
Considering integer division what would be displayed by the following expression?
txtOutput.Text = (12.1 \ 3) Mod 2
1) 4.033
2) 0
3) 2
4) 3
2) 0
If x = 12, evaluate the expression (x + 5) mod 3
1) 2
2) 0
3) 3
4) 4
1) 2
The expression “if choice 2” is
1) checking if the value of choice is 2
2) checking if the value of choice is not equal to 2
3) assigning the value of 2 to choice
4) none of the above
2) checking if the value of choice is not equal to 2
Three TYPES of languages discussed were
1) Fortran, machine, high-level
2) C++, assembly, Java
3) Pascal, assembly, Ada
4) High-level, machine, assembly
4) High-level, machine, assembly
What will the following expression display on the screen.
Dim a as String = “”
a = “Hello”
a &= “ World”
txtOutput.Text = a
1) Hello
2) World
3) Hello World
4) Hello World
4) Hello World
Which conversion specifier handles the display of floating point numbers
1) {0:F}
2) {0:X}
3) {0:E}
4) {0:G}
1) {0:F}
Which of the following is not a reserved word
1) Dim
2) Integer
3) Double
4) Celsius
4) Celsius
Which of the following statments is true
1) the keywords module and end module end the body of the module
2) the keywords sub main() and end sub end the body of the module
3) the keywords function() and end function end the body of the module
4) the keywords if and end if end the body of the module
1) the keywords module and end module end the body of the module
Objects normally are not allowed to know how other objects are implemented. This is called __________.
A) inheritance
B) encapsulation
C) blindfolding
D) polymorphsim
B) encapsulation
Which of the following is not supported image format:
Incorrect Response
A) GIF
B) TIF
C) PNG
D) JPEG
B) TIF
A comment in Visual Basic begins with:
A) /*
B) //
C) ‘
D) */
C) ‘
A Form’s ___________ event occurs just before the Form is displayed on the screen, typically as a result of executing the program.
A) Load
B) Display
C) Execute
D) Click
A) Load
Which operator performs String concatenation?
A) @
B) &
C) %
D) #
B) &
Which of the following represents the “is equal” to “ equality operator:
A) ==
B) =
C) !=
D) <>
B) =
The ___________ event is a TextBox’s default event.
A) TextEntered
B) Click
C) Load
D) TextChanged
D) TextChanged
Which of the following is true?
A) Pseudocode is used to specify the variables needed by the program.
B) Pseudocode is used to describe executable statements that will eventually be translated by the programmer into a program.
C) Psedocode translate high level language to an assembly language.
D) Pseudocode compiles into machine code.
B) Pseudocode is used to describe executable statements that will eventually be translated by the programmer into a program.
Keyword _____________ is used to specify a range in Case statement.
A) Also
B) Between
C) To
D) From
C) To