Ask Question
17 March, 18:07

Write an expression that will print "Dollar or more" if the value of num_cents is at least a dollar (100 cents is a dollar). Sample output with input: 109 Dollar or more

+3
Answers (1)
  1. 17 March, 21:28
    0
    num_cents = 109

    if num_cents > = 100:

    print ('Dollar or more')

    else:

    print ('not a dollar')

    Explanation:

    Assign the value of 109 to num_cents. Check if num_cents value is greater than 100, then print dollar or more. Else the value entered is less than 100 cents so it is not a dollar.
Know the Answer?
Not Sure About the Answer?
Get an answer to your question ✅ “Write an expression that will print "Dollar or more" if the value of num_cents is at least a dollar (100 cents is a dollar). Sample output ...” in 📙 Computers & Technology if there is no answer or all answers are wrong, use a search bar and try to find the answer among similar questions.
Search for Other Answers