Python Forum
Printing simple calculator answer
Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Printing simple calculator answer
#1
Don't laugh too hard, I'm literally week one of studying.
I have (I think) created a simple calculator to come up with the break even point of items to be sold, why won't this print the final break_even answer?? Thank You

print('Cost_to_produce_each_item = 20.00')
print('The_sale_price_per_item = 40.00')
print('Fixed_costs = 50000.00')
print('Profit_per_item = 20.00')

Cost_to_produce_each_item = float(input("20.00: "))
The_sale_price_per_item = float(input("40.00: "))
Fixed_costs = float(input("50000.00: "))
Profit_per_item = float(input("20.00: "))
break_even = (Fixed_costs) / (Profit_per_item)
print(break_even)
buran write Dec-05-2020, 09:59 AM:
Please, use proper tags when post code, traceback, output, etc. This time I have added tags for you.
See BBcode help for more info.
Reply
#2
what input do you provide?
If you can't explain it to a six year old, you don't understand it yourself, Albert Einstein
How to Ask Questions The Smart Way: link and another link
Create MCV example
Debug small programs

Reply
#3
Looks like you don't have a good understanding of how input command works. You need to input something from the keyboard. Please check out my "User Input Tutorial" at https://www.youtube.com/watch?v=fEvqiTfrxBU&t=75s
Reply


Possibly Related Threads…
Thread Author Replies Views Last Post
Question Answer for newbie, Sqlite3 Froger 2 898 Sep-27-2023, 05:33 PM
Last Post: noisefloor
  Coding answer for newbie cg3 2 1,198 Aug-05-2023, 12:17 PM
Last Post: jefsummers
  Simple calculator ryza 3 1,175 Sep-21-2022, 04:42 PM
Last Post: deanhystad
  Simple Distance Between Points Calculator Spade 1 1,768 Sep-17-2021, 03:14 PM
Last Post: DeaD_EyE
  What am I doing wrong to not get the answer pav1983 7 3,758 Jun-25-2020, 08:53 PM
Last Post: ndc85430
  Need help with an assignment, not an answer. celtickodiak 4 2,988 Oct-01-2019, 02:04 PM
Last Post: jefsummers
  simple calculator shakeelthomas 11 6,258 Jul-23-2018, 10:47 PM
Last Post: shakeelthomas

Forum Jump:

User Panel Messages

Announcements
Announcement #1 8/1/2020
Announcement #2 8/2/2020
Announcement #3 8/6/2020