4 Replies - 1511 Views - Last Post: 08 December 2009 - 10:21 PM Rate Topic: -----

#1 MGOBLUE021  Icon User is offline

  • New D.I.C Head

Reputation: -3
  • View blog
  • Posts: 13
  • Joined: 07-December 09

Need Help With Python Coding

Posted 07 December 2009 - 08:34 AM

I just need someone's help starting out this code in Python. Any help would be greatly appreciated!

A global garbage company wants you to design and write a program that will do the following things:
Take in the name of a client
Take in how much tons of garbage was collected for each month
Calculate the yearly average of garbage for that client
Determine the cost associated with the yearly average based on the following:
o If the average is between 0 and 20 ton, then the cost per ton is 4,500.
o If the average is between 21 and 50 ton, then the cost per ton is 5,500.
o If the average is between 51 and 100 ton, then the cost per ton is 6,500.
o If the average is above 100 ton, then the cost per ton is 7,000.
Display the name of the company, the total tons of garbage collected, the average tonnage of garbage, and the total cost it will incur for that landfill.

This program should use loops, including one to run the program multiple times. It will also use decisions and modules/functions. Be sure to include input validation.

Is This A Good Question/Topic? 0
  • +

Replies To: Need Help With Python Coding

#2 chemicalfan  Icon User is offline

  • D.I.C Head

Reputation: 4
  • View blog
  • Posts: 88
  • Joined: 16-October 09

Re: Need Help With Python Coding

Posted 07 December 2009 - 05:09 PM

Ok, so what do you have so far?
Was This Post Helpful? 0
  • +
  • -

#3 MGOBLUE021  Icon User is offline

  • New D.I.C Head

Reputation: -3
  • View blog
  • Posts: 13
  • Joined: 07-December 09

Re: Need Help With Python Coding

Posted 08 December 2009 - 01:02 PM

View Postchemicalfan, on 7 Dec, 2009 - 04:09 PM, said:

Ok, so what do you have so far?

I don't have anything yet. I was just wondering if I could get some help starting it out or something...
Thanks!
Was This Post Helpful? 0
  • +
  • -

#4 JackOfAllTrades  Icon User is offline

  • Saucy!
  • member icon

Reputation: 6107
  • View blog
  • Posts: 23,659
  • Joined: 23-August 08

Re: Need Help With Python Coding

Posted 08 December 2009 - 04:46 PM

That's not how it works here. You need to show some effort. Please re-read our policy:

Dream.In.Code has a policy by which we prefer to see a good faith effort on your part before providing source code for homework assignments. Please post the code you have written in an effort to resolve the problem, and our members would be happy to provide some guidance. Be sure to include a description of any errors you are encountering as well.

Please post like this:

Thank you for helping us helping you.
Was This Post Helpful? 0
  • +
  • -

#5 Lemur  Icon User is offline

  • Pragmatism over Dogma
  • member icon


Reputation: 1383
  • View blog
  • Posts: 3,514
  • Joined: 28-November 09

Re: Need Help With Python Coding

Posted 08 December 2009 - 10:21 PM

Tell you what, because you seem like you really have some potential there to do something with this project and you just need some code to start you out I have the perfect site for all of your problems, it helped me learn everything I know as well as most of the coders here. This site is the most useful thing ever:
http://lmgtfy.com/?q=Python+Primer
Was This Post Helpful? 0
  • +
  • -

Page 1 of 1