CMP1 4.2 TestBank Questions for Computer Programming I Obj 4.2

Question Answer
Which would be appropriate as an object name? txtHoursWorked
Why is label not a valid variable name? It is a Visual Basic reserved keyword.
A variable named intGrade is of what data type? Integer
A variable named blnIsTrue is of what data type? Boolean
What is an appropriate name for a constant according to Hungarian notation? decRATE
A variable named strName is of what data type? String
What is an appropriate name for a textbox according to Hungarian notation? txtName
According to Hungarian notation, what is an appropriate name for a Textbox? txtName
A variable named decBonus is of what data type? Decimal
Which is a proper name for a button according to Hungarian notation? btnAdd
Which would best represent a variable that will hold a true or false value if an entry was valid? Dim blnlsValid As Boolean
Which would best represent a Button control object that will be used to calculate an average? btnCalcAverage
In the statement, lblMessage.Text = "This is a label." What does lblMessage refer to? Label control
If a student needed to declare a variable to hold values representing a grade point average (GPA), which would be the best declaration given programming naming conventions? Dim dblGPA As Double
Which would be appropriate as a variable? strFirstName
A variable named dblTaxRate is of what data type? Double

Leave a Reply

Your email address will not be published.