answer.
Ask question
Login Signup
Ask question
All categories
  • English
  • Mathematics
  • Social Studies
  • Business
  • History
  • Health
  • Geography
  • Biology
  • Physics
  • Chemistry
  • Computers and Technology
  • Arts
  • World Languages
  • Spanish
  • French
  • German
  • Advanced Placement (AP)
  • SAT
  • Medicine
  • Law
  • Engineering
den301095 [7]
2 years ago
5

Budget Analysis (use while loop) Write a program that asks the user to enter the amount that he or she has budgeted for a month.

A loop should then prompt the user to enter each of his or her expenses for the month and keep a running total. When the loop finishes, the program should display the amount that the user is over or under budget.
Computers and Technology
1 answer:
Agata [3.3K]2 years ago
6 0

Answer:

print('This program will help you determine whether you\'ve budgeted enough ' +

     'for your expenses. You\'ll just need to enter your budget and the ' +

     'cost of each of your expenses for the month and we will calculate ' +

     'the balance.')

budget = float(input('How much have you budgeted this month? '))

expenses = 0

check = 0

while check >= 0:

   check = float(input('Enter an expense amount or -1 to quit: '))

   if check != -1:

       expenses += check

balance = budget - expenses

if balance < 0:

   print('\nYou haven\'t budgeted enough. You\'re going to be $', \

         format(-1 * balance, ',.2f'), ' short this month.', sep = '')

elif balance == 0:

   print('\nBe careful. You\'ve budgeted just enough to make it through ' +

         'the month.')

else:

   print('\nYou will have $', format(balance, ',.2f'), ' extra this month.', \

         sep = '')

You might be interested in
What statement best describes Konrad Zuse?
vazorg [7]

Answer:

D

Explanation:

Konrad Zuse was a German civil engineer, inventor and computer pioneer. His greatest achievement was the world's first programmable computer; the functional program-controlled Turing-complete Z3 became operational in May 1941.

8 0
2 years ago
Read 2 more answers
A domain's ____ settings must be configured correctly so that the mail transfer agent (mta) can establish a connection with a re
Oksi-84 [34.3K]

i think its firewall. Because the firewall can block protocols are are not allowed by an administrator. especially over a remote connection

5 0
2 years ago
+10 POINTS AND BRAINLIEST!! HELP ME PLEASE!!~~~
Karo-lina-s [1.5K]

+10 POINTS AND BRAINLIEST!! HELP ME PLEASE!!~~~

Which statement describes what happens when a user configures No Automatic Filtering in Junk Mail Options?

No messages will ever be blocked from the user’s mailbox.

Messages can still be blocked at the server level.

Messages cannot be blocked at the network firewall.

Most obvious spam messages will still reach the client computer.+10 POINTS AND BRAINLIEST!! HELP ME PLEASE!!~~~

Which statement describes what happens when a user configures No Automatic Filtering in Junk Mail Options?

No messages will ever be blocked from the user’s mailbox.

Messages can still be blocked at the server level.

Messages cannot be blocked at the network firewall.

Most obvious spam messages will still reach the client computer.+10 POINTS AND BRAINLIEST!! HELP ME PLEASE!!~~~

Which statement describes what happens when a user configures No Automatic Filtering in Junk Mail Options?

No messages will ever be blocked from the user’s mailbox.

Messages can still be blocked at the server level.

Messages cannot be blocked at the network firewall.

Most obvious spam messages will still reach the client computer.+10 POINTS AND BRAINLIEST!! HELP ME PLEASE!!~~~

Which statement describes what happens when a user configures No Automatic Filtering in Junk Mail Options?

No messages will ever be blocked from the user’s mailbox.

Messages can still be blocked at the server level.

Messages cannot be blocked at the network firewall.

Most obvious spam messages will still reach the client computer.+10 POINTS AND BRAINLIEST!! HELP ME PLEASE!!~~~

Which statement describes what happens when a user configures No Automatic Filtering in Junk Mail Options?

No messages will ever be blocked from the user’s mailbox.

Messages can still be blocked at the server level.

Messages cannot be blocked at the network firewall.

Most obvious spam messages will still reach the client computer.

<em><u>please</u></em><em><u> </u></em><em><u>mark</u></em><em><u> </u></em><em><u>me</u></em><em><u> </u></em><em><u>as</u></em><em><u> </u></em><em><u>brainliest</u></em><em><u>. </u></em><em><u>.</u></em><em><u>.</u></em><em><u>.</u></em><em><u>.</u></em><em><u>.</u></em><em><u>.</u></em><em><u>.</u></em>

<em><u>follow</u></em><em><u> </u></em><em><u>me</u></em><em><u>.</u></em><em><u>.</u></em><em><u>.</u></em><em><u>my</u></em><em><u> </u></em><em><u>fr</u></em><em><u>.</u></em><em><u>.</u></em><em><u>.</u></em><em><u>.</u></em><em><u>.</u></em><em><u>.</u></em><em><u>.</u></em><em><u>.</u></em><em><u>.</u></em>

6 0
2 years ago
Assume that name has been declared suitably for storing names (like "Misha", "Emily" and "Sofia"). Assume also that stdin is a v
zaharov [31]

Answer:

// program in java.

import java.util.*;

// class definition

class Main

{// main method of the class

public static void main (String[] args) throws java.lang.Exception

{

   try{

    // object to read input

Scanner scr=new Scanner(System.in);

 // ask to enter name

System.out.print("Enter Your name: ");

 // read name from user

String NAME=scr.nextLine();

// print message

System.out.println("Greetings,"+NAME);

     

   }catch(Exception ex){

       return;}

}

}

Explanation:

Read name from user with the help of scanner object and assign it to variable "NAME".Then print a Greetings message as "Greetings,NAME" where NAME will be  replaced with user's input name.

Output:

Enter Your name: Rachel                                                                                                    

Greetings,Rachel

5 0
2 years ago
ACCOUNTING
ivann1987 [24]

last question is D

Hope this helps

7 0
2 years ago
Read 2 more answers
Other questions:
  • Represent decimal number 8620 in (a) BCD, (b) excess-3 code, (c)2421 code, and (d) as a binary number
    7·1 answer
  • Which process is used to protect transmitted data in a vpn?
    12·1 answer
  • Suppose a digital camera has a storage capacity of 256mb. how many photographs could be stored in the camera if each consisted o
    8·1 answer
  • Nick won a $1,000 lottery prize. He can't decide what he should spend the money on. For some time now, he has been planning to b
    5·1 answer
  • Ismael would like to insert a question mark symbol in his document. What steps will he need to follow to do that?
    5·2 answers
  • Explain how buyers and sellers factor into setting the stock price for a company’s shares.
    13·1 answer
  • The ________ is the agreed-upon interface between all the software that runs on the machine and the hardware that executes it. I
    5·1 answer
  • Juan, a network user, sends an email to you, the IT admin of the network, stating that his account is locked because he has lost
    14·1 answer
  • Create a program that includes a function called toUpperCamelCase that takes a string (consisting of lowercase words and spaces)
    9·1 answer
  • Lucy is completing a project as part of a science class using materials she found online. Which of the following is MOST LIKELY
    5·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!