Ask Question
5 March, 14:53

If dblMiles > = 500 Then

dblMiles = dblMiles * 0.45

Else

dblMiles = dblMiles * 0.25

End If

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

+1
Answers (1)
  1. 5 March, 15:11
    0
    225

    Explanation:

    The given codes contain an if-else block. If the dblMiles bigger than or equal to 500, the dblMiles will be multiplied with 0.45 or else multiplied with 0.25.

    If the initial value of dblMiles is 575, the expression dblMiles >=500 will be evaluated to true and if block statement dblMiles = dblMiles * 0.45 will be executed and the 575 * 0.45 = 258.75

    The value of 258.75 will be assigned to dblMiles to overwrite the previous value.
Know the Answer?
Not Sure About the Answer?
Find an answer to your question ✅ “If dblMiles > = 500 Then dblMiles = dblMiles * 0.45 Else dblMiles = dblMiles * 0.25 End If The dblMiles variable contains the number 575 ...” in 📘 Computers and Technology if you're in doubt about the correctness of the answers or there's no answer, then try to use the smart search and find answers to the similar questions.
Search for Other Answers