98-361

98-361 practice questions, page 4 of 7, with answer review and explanations.

Question 16

You have a stack that contains integer values. The values are pushed onto the stack in the following order: 2,4,6,8. The following sequence of operations is executed: Pop - Push 3 - Pop - Push 4 - Push 6 - Push 7 - Pop - Pop - Pop - What is the value of the top element after these operations are executed?

  1. 2
  2. 3
  3. 6
  4. 7

Question 17

What are two methods that can be used to evaluate the condition of a loop at the start of each iteration? (Each correct answer presents a complete solution. Choose two. )

  1. If
  2. Do. . . While
  3. For
  4. While

Question 18

You need to evaluate the following expression: (A>B) AND (C<D) What is the value of this expression if A=3, B=4, C=4, and D=5?

  1. 0
  2. 4
  3. 5
  4. False
  5. Null
  6. True

Question 19

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?

  1. String
  2. Float
  3. Char
  4. Decimal

Question 20

You execute the following code. What will the variable result be?

  1. 0
  2. 1
  3. 2
  4. 3