Question: Programming with Microsoft Visual Basic QUESTION 1 1.In the mathematical expression 12/6/2, the answer is ____. a. 4 b. 1 c. 2 d. 3 2

Programming with Microsoft Visual Basic

QUESTION 1

1.In the mathematical expression 12/6/2, the answer is ____.

a.

4

b.

1

c.

2

d.

3

2 points

QUESTION 2

1.A ____ represents information that is passed to the procedure when the event occurs.

a.

solution

b.

statement

c.

condition

d.

parameter

2 points

QUESTION 3

1.A control's ____ event occurs when a change is made to the contents of a control's Text property.

a.

TextModified

b.

CodeChanged

c.

TextChanged

d.

ChangedText

2 points

QUESTION 4

1.A memory variable that is a Double data type requires ____ bytes of storage.

a.

8

b.

6

c.

2

d.

4

2 points

QUESTION 5

1.Aside from letters and numbers, a variable name in Visual Basic can only contain the _________ character.

a.

percent sign (%)

b.

underscore (_)

c.

ampersand (&)

d.

exclamation mark (!)

2 points

QUESTION 6

1.Case-Based Critical Thinking Questions

Case 1: Jack of All Trades

You've been asked to design an application for Jack of All Trades, which rents small power equipment to commercial and residential customers, to process its transactions. ThestrCustomervariable will be used to determine whether a customer is commercial (C) or residential (R). Commercial customers receive a 10% discount if they are members of the Rental Rewards Program. Residential customers receive a 5% discount if they are members.

The application needs to display a message box to remind the clerk to ask customers to join the Rental Rewards Program when they check out. This message box should only display if the customer is not currently in the program. Which of the following If clauses would evaluate to True and display the message box for the clerk?

a.

If strMember = "Y" Then

b.

If strMember = "N" Then

c.

If strMember <> "Y" Then

d.

a and c

2 points

QUESTION 7

1.Case-Based Critical Thinking Questions

Case 1: Jack of All Trades

You've been asked to design an application for Jack of All Trades, which rents small power equipment to commercial and residential customers, to process its transactions. ThestrCustomervariable will be used to determine whether a customer is commercial (C) or residential (R). Commercial customers receive a 10% discount if they are members of the Rental Rewards Program. Residential customers receive a 5% discount if they are members.

Which of the following If clauses would evaluate to True and apply the 10% discount for a commercial customer?

a.

If strCustomer <> "R" OrElse strMember = "Y"

b.

If strCustomer = "C" AndAlso strMember = "Y"

c.

If strCustomer = "C" OrElse strMember = "Y"

d.

If strCustomer <> "C" AndAlso strMember <> "Y"

2 points

QUESTION 8

1.Case-Based Critical Thinking Questions

Case 1: Jack of All Trades

You've been asked to design an application for Jack of All Trades, which rents small power equipment to commercial and residential customers, to process its transactions. ThestrCustomervariable will be used to determine whether a customer is commercial (C) or residential (R). Commercial customers receive a 10% discount if they are members of the Rental Rewards Program. Residential customers receive a 5% discount if they are members.

The message provided when a customer is not a current member of the Rental Rewards Program is "Enroll this customer in the Rental Rewards Program?". The clerk can click "Yes" to begin the application process, or "No" to enter a note that the customer has declined the offer. What type of selection structure is used to accomplish this?

a.

a single-alternative selection structure

b.

a yes/no selection structure

c.

a dual-alternative selection structure

d.

a decline/accept selection structure

2 points

QUESTION 9

1.Case-Based Critical Thinking Questions

Case 1: Jack of All Trades

You've been asked to design an application for Jack of All Trades, which rents small power equipment to commercial and residential customers, to process its transactions. ThestrCustomervariable will be used to determine whether a customer is commercial (C) or residential (R). Commercial customers receive a 10% discount if they are members of the Rental Rewards Program. Residential customers receive a 5% discount if they are members.

You meet with the manager of Jack of All Trades and she tells you that occasionally a customer requests more than one piece of equipment at the same time. She'd like to be able to handle all requests from a single customer in one transaction. Based on this feedback, you decide to use ____________ for equipment selection in the interface.

a.

radio buttons

b.

check boxes

c.

text boxes

d.

labels

2 points

QUESTION 10

1.Case-Based Critical Thinking Questions

Case 1: PetPals

You have been hired by PetPals Veterinary Clinic to modify an application. The application is used to enter and save all patient (pet) information obtained during an office visit.

The pet's temperature is recorded at every visit, and it may contain a decimal place. What data type is best for storing this data?

a.

Decimal

b.

Integer

c.

Double

d.

String

2 points

QUESTION 11

1.Case-Based Critical Thinking Questions

Case 1: PetPals

You have been hired by PetPals Veterinary Clinic to modify an application. The application is used to enter and save all patient (pet) information obtained during an office visit.

The account number for each pet must be available to be used by all procedures in the form. You should make sure the account number is declared using the ____ keyword.

a.

Public

b.

Val

c.

Private

d.

Dim

2 points

QUESTION 12

1.Consider the expression 3 * 2 ^ 2 < 16 + 5 AndAlso 100 / 10 * 2 > 15 - 3. Which operation is performed last?

a.

AndAlso

b.

^

c.

<

d.

>

2 points

QUESTION 13

1.Consider the expression 3 * 2 ^ 2 < 16 + 5 AndAlso 100 / 10 * 2 > 15 - 3. Which operation is performed first?

a.

*

b.

/

c.

^

d.

+

2 points

QUESTION 14

1.Consider the expression 3 * 2 ^ 2 < 16 + 5 AndAlso 100 / 10 * 2 > 15 - 3. Which operation is performed second?

a.

^

b.

/

c.

*

d.

+

2 points

QUESTION 15

1.Every numeric data type in Visual Basic has a ____ method that can be used to convert a string to that numeric data type.

a.

Format

b.

Convert

c.

Number

d.

TryParse

2 points

QUESTION 16

1.Except for the ____ operator, all of the logical operators allow you to combine two or more conditions into one compound condition.

a.

Not

b.

And

c.

Or

d.

Xor

2 points

QUESTION 17

1.If dblMiles >= 500 Then

dblMiles = dblMiles * 0.45

Else

dblMiles = dblMiles * 0.25

End If

ThedblMilesvariable contains the number 575 before the code above is processed. What value will be in the variable after the code is processed?

a.

143.75

b.

0

c.

258.75

d.

225

2 points

QUESTION 18

1.If the intQuantity and decPrice variables contain the numbers 3 and 15.75, respectively, the condition If intQuantity > 0 AndAlso intQuantity < 10 OrElse decPrice > 20 will evaluate to ____.

a.

No

b.

False

c.

True

d.

Yes

2 points

QUESTION 19

1.In the mathematical expression 4 * 3 + 15 / 3 - 6, which operation is performed first?

a.

*

b.

/

c.

-

d.

+

2 points

QUESTION 20

1.In the mathematical expression 4 * 3 + 15 / 3 - 6, which operation is performed last?

a.

*

b.

+

c.

-

d.

/

2 points

QUESTION 21

1.Programmers can create ____, which are memory locations inside the computer, to store data.

a.

integers

b.

strings

c.

characters

d.

variables

2 points

QUESTION 22

1.Short English-like phrases written to represent the steps a program must take to solve a particular problem are called ____.

a.

object code

b.

pseudocode

c.

flowcharts

d.

macro code

2 points

QUESTION 23

1.Specifying the number of decimal places and the special characters to display in a number is called ____.

a.

designing

b.

formatting

c.

concatenating

d.

shredding

2 points

QUESTION 24

1.The ____ of a variable indicates where the declared memory location can be used in an application's code.

a.

dimension

b.

extent

c.

scope

d.

type

2 points

QUESTION 25

1.The ____ operator expresses "not equal to."

a.

>

b.

<>

c.

<=

d.

>=

2 points

QUESTION 26

1.The ____ operator is evaluated first in the following expression: 9 * 2 - 8 > 5 + 2 / 2.

a.

>

b.

*

c.

+

d.

-

2 points

QUESTION 27

1.The ____ operator is evaluated last in the following expression: 9 * 2 - 8 > 5 + 2 / 2.

a.

*

b.

-

c.

>

d.

+

2 points

QUESTION 28

1.The _________ symbol in a flowchart represents the condition in a selection structure.

a.

rectangle

b.

parallelogram

c.

diamond

d.

oval

2 points

QUESTION 29

1.The ___________ symbol in a flowchart represents input tasks and output tasks.

a.

diamond

b.

oval

c.

parallelogram

d.

rectangle

2 points

QUESTION 30

1.The assignment operator in Visual Basic is the ____ symbol.

a.

^

b.

<

c.

=

d.

>

2 points

QUESTION 31

1.The symbol used in code for assignment is the ____ symbol.

a.

^

b.

<

c.

=

d.

2 points

QUESTION 32

1.To prevent a text box from accepting inappropriate characters, you first use the e parameter's ____ property to determine the key that the user pressed.

a.

KeyEnter

b.

KeyPress

c.

KeyChar

d.

KeyStruck

2 points

QUESTION 33

1.To specify a range of values in a Select Case statement's clause, use the _______ keyword when you know both the upper and lower values in the range.

a.

To

b.

Is

c.

Of

d.

From

2 points

QUESTION 34

1.Use the ____ flowchart symbol to represent the selection structure's condition.

a.

parallelogram

b.

rectangle

c.

oval

d.

diamond

2 points

QUESTION 35

1.What is the value of the following expression: 9 * 2 - 8 > 5 + 2 / 2?

a.

10

b.

False

c.

6

d.

True

2 points

QUESTION 36

1.Which of the following can store a number containing a decimal place?

a.

Double

b.

Integer

c.

String

d.

Long

2 points

QUESTION 37

1.Which of the following statements assigns the contents of the txtGrade control, in uppercase, to the strGrade variable?

a.

If strGrade = txtGrade.Text.ToUpper Then

b.

strGrade = txtGrade.Text.ToUpper

c.

strGrade.ToUpper = txtGrade.Text

d.

txtGrade.Text.ToUpper = strGrade

2 points

QUESTION 38

1.Which of the following statements declares a class-level variable?

a.

Class dblHeight As Double

b.

Private dblHeight As Double

c.

Dim dblHeight As Double

d.

Private Dim dblHeight As Double

2 points

QUESTION 39

1.With the KeyPress event, use the e parameter's ____ property to cancel the key if it is an inappropriate one.

a.

Handled

b.

KeyEnter

c.

Check

d.

KeyChar

2 points

QUESTION 40

1.You create a named constant using the ____ statement.

a.

Perm

b.

Const

c.

Fixed

d.

ConstantFixed

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Mathematics Questions!