How does a console-based application differ from a Windows Store app?
B
None
DRAG DROP You are developing an application to display track and field race results.
The application must display the race results twice. The first time it must display only the winner and runner-up. The second
time it must display all participants. The code used to display results is shown below.
You need to implement the Rankings() function.
Complete the function to meet the requirements. (To answer, drag the appropriate code segment from the column on the left
to its location on the right. Each code segment may be used once, more than once, or not at all. Each correct match is worth
one point.)
Select and Place:
Explanation:
* You can use an Exit Function or Return statement to end the iteration. Return expression is required in a Function, Get, or
Operator procedure. Expression that represents the value to be returned to the calling code.
The following functions are defined:
What does the console display after the following line?
Printer(2)
B
None
HOTSPOT
You are reviewing the following code that saves uploaded images.
For each of the following statements, select Yes if the statement is true. Otherwise, select No. Each correct selection is
worth one point.
Hot Area:
You execute the following code.
What will the variable iResult be?
B
None
You are building a web application that enables international exchange students to schedule phone calls with their
prospective schools.
The application allows students to indicate a preferred date and time for phone calls. Students may indicate no preferred
time by leaving the date and time field empty. The application must support multiple time zones.
Which data type should you use to record the student's preferred date and time?
B
Explanation:
datetimeoffset: Defines a date that is combined with a time of a day that has time zone awareness and is based on a 24-hour
clock.
Incorrect:
Date: Defines a date.
sByte: The sbyte keyword indicates an integral type that stores values in the range of -128 to 127.
You are creating the necessary variables for an application. The data you will store in these variables has the following
characteristics:
Consists of numbers
Includes numbers that have decimal points
Requires more than seven digits of precision
You need to use a data type that will minimize the amount of memory that is used.
Which data type should you use?
D
Explanation:
The double keyword signifies a simple type that stores 64-bit floating-point values. Precision: 15-16 digits
You execute the following code.
How many times will the word Hello be printed?
B
Explanation:
The mod operator computes the remainder after dividing its first operand by its second. All numeric types have predefined
remainder operators.
In this case the reminder will be nonzero 50 times (for i with values 1, 3, 5,..,99).
Class C and Class D inherit from Class
B. Class B inherits from Class
D
None
Which type of function can a derived class override?
A
Explanation:
The Overridable modifier allows a property or method in a class to be overridden in a derived class.
You cannot specify Overridable or NotOverridable for a Private method.
You have a class named Truck that inherits from a base class named Vehicle. The Vehicle class includes a protected
method named brake ().
How should you call the Truck Class implementation of the brake () method?
A
Explanation:
The MyBase keyword behaves like an object variable referring to the base class of the current instance of a class.MyBase is
commonly used to access base class members that are overridden or shadowed in a derived class.
You are creating an application that presents users with a graphical interface in which they computers that do not have
network connectivity.
Which type of application should you choose?
C
Explanation:
Use Windows Forms when a GUI is needed.
You create an object of type ANumber. The class is defined as follows.
The code is executed as follows.
Dim mynumber As ANumber = new ANumber(3);
What is the value of _number after the code is executed?
C
None
You are designing a class for an application. You need to restrict the availability of the member variable accessCount to the
base class and to any classes that are derived from the base class.
Which access modifier should you use?
B
None
You are creating a variable for an application.
You need to store data that has the following characteristics in this variable:
Consists of numbers and characters
Includes numbers that have decimal points
Which data type should you use?
C
Explanation:
Need a string to store characters.