Visual Basic Programming Fundamentals

Quiz covering basic programming concepts including loops, error handling, exceptions, and Windows Forms CheckBox controls

10 Questions Published

Questions

Question 1 Multiple Choice (Single Answer)

The advantage of For...Next loops over Do...Loops is that they are:

  1. easier to read and maintain.
  2. less prone to being infinite loops.
  3. good for working with arrays.
  4. Both a and b.
  5. All of the above.
Question 2 Multiple Choice (Single Answer)

Which is not a valid Exit statement?

  1. Exit Do
  2. Exit For
  3. Exit Form
  4. Exit Select
  5. Exit Sub
Question 3 Multiple Choice (Single Answer)

A sentinel value:

  1. is used to prevent infinite loops.
  2. must be a negative value.
  3. signals the end of a list of data.
  4. Both a and b.
  5. All of the above.
Question 4 Multiple Choice (Single Answer)

Which function should be used to validate that input is not a string before performing arithmetic operations?

  1. IsArithmetic
  2. IsNotString
  3. IsNumeric
  4. IsString
  5. IsValue
Question 5 Multiple Choice (Single Answer)

Which is not a type of error programmers look for?

  1. Logic
  2. Runtime
  3. Superficial
  4. Syntax
  5. All are errors programmers look for.
Question 6 Multiple Choice (Single Answer)

Which action will raise an exception?

  1. Dividing by zero.
  2. Assigning the string "Hi" to an integer variable.
  3. Accessing an empty CD drive.
  4. Both a and b.
  5. All of the above.
Question 7 Multiple Choice (Single Answer)

An Exception is another name for a:

  1. compile error.
  2. logic error.
  3. runtime error.
  4. superficial error.
  5. syntax error.
Question 8 Multiple Choice (Single Answer)

What is the most number of states a CheckBox can have?

  1. 1
  2. 2
  3. 3
  4. 4
Question 9 Multiple Choice (Single Answer)

What is the standard prefix for the name of a CheckBox?

  1. chb
  2. chk
  3. ckb
  4. ckx
  5. cbx
Question 10 Multiple Choice (Single Answer)

A CheckBox can also appear as a(n):

  1. button.
  2. RadioButton.
  3. ScrollBar.
  4. Both a and b.
  5. All of the above.