Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > comp.lang.python > #29461 > unrolled thread
| Started by | Dennis Lee Bieber <wlfraed@ix.netcom.com> |
|---|---|
| First post | 2012-09-18 22:05 -0400 |
| Last post | 2012-09-18 22:05 -0400 |
| Articles | 1 — 1 participant |
Back to article view | Back to comp.lang.python
This discussion starts older than the indexed window; earlier articles aren't shown. The article labeled Started by
below is the oldest one visible, not the original post.
Re: Fwd: Programming Issues Dennis Lee Bieber <wlfraed@ix.netcom.com> - 2012-09-18 22:05 -0400
| From | Dennis Lee Bieber <wlfraed@ix.netcom.com> |
|---|---|
| Date | 2012-09-18 22:05 -0400 |
| Subject | Re: Fwd: Programming Issues |
| Message-ID | <mailman.899.1348020348.27098.python-list@python.org> |
On Tue, 18 Sep 2012 20:47:45 -0400, Nathan Spicer <njspicy@gmail.com>
declaimed the following in gmane.comp.python.general:
> ---------- Forwarded message ----------
> From: Nathan Spicer <njspicy@gmail.com>
> Date: Tue, Sep 18, 2012 at 8:32 PM
> Subject: Programming Issues
> To: webmaster@python.org
>
Asking the /webmaster/ at Python.org?
>
> Hello,
>
> My name is Nathan Spicer. I'm taking a computer programming class using
> python. I have a project that's due in a week and I'm not certain how to d
> this. I'm totally new to this form of programming. I've stated the scope of
> the project below. Any form of help would be great.
>
What were the prerequisites of the class? Everything you need should
have been covered before the assignment was even given. If it wasn't,
you should be asking the instructor.
>
> Ask the user for the amount of change expressed in cents. Your program must
> compute and display the number of half-dollars, quarters, dimes, nickels,
> and pennies to be returned.
> Return as many half-dollars as possible, then quarters, dimes, nickels, and
> pennies, in that order.
> Your program must allow the user to continue entering different amounts of
> change until they enter 0 to indicate they are finished. If the user enters
> a negative number, inform them of their mistake and ask them to enter a
> correct value.
>
Sounds like a typical second or third assignment in programming;
there must be hundreds of examples out there.
http://en.wikipedia.org/wiki/Change-making_problem
All it needs are:
a loop structure around the input
conversion of text input to numeric
a conditional test
modulo arithmetic
an output statement
So what are you having problems with?
--
Wulfraed Dennis Lee Bieber AF6VN
wlfraed@ix.netcom.com HTTP://wlfraed.home.netcom.com/
Back to top | Article view | comp.lang.python
csiph-web