python newbie

broebel computer.problemen at skynet.be
Thu Jan 8 17:50:37 EST 2004


hey,

I'm a newbie in the programming world.
I just started and already I'm in a whole lot of problems.

first problem is the fact that I started out with a little program who was
part of a course but the problem is when I launch the program. I don't have
the time to see the result because the screen closes immediately.
Can anyone explain what's happening.

thanks in advance

    me,

# Een bedrag gepast betalen met zo min mogelijk euromunten

bedrag = input ( 'Geef bedrag tussen 0 en 500 eurocent: ' )

for munt in 200, 100, 50, 20, 10, 5, 2, 1 :
    aantal = 0

    while bedrag >= munt :
        aantal = aantal + 1
        bedrag = bedrag - munt

    if aantal > 0 :
        print aantal, 'x', munt





More information about the Python-list mailing list