Indentation
Michal Wallace
sabren at manifestation.com
Tue Jun 19 12:14:15 EDT 2001
On Tue, 19 Jun 2001, GWYoder wrote:
> I'm still trying here is what I'm getting...
>
> Python 2.1 (#15, Apr 16 2001, 18:25:49) [MSC 32 bit (Intel)] on win32
> Type "copyright", "credits" or "license" for more information.
> IDLE 0.8 -- press F1 for help
> >>> y = 1900
> >>> leap = "no"
> >>> if y % 400 == 0:
> leap = "yes"
> elif y % 100 == 0:
how are you getting to the line starting with "leap"?
it SHOULD look like this:
>>> y=1900
>>> leap="no"
>>> if y % 400==0:
... leap="yes"
... elif y % 100==0:
... pass # whatever the rest of the code is
...
>>>
you just press enter once after each line, until you're done with
the entire if,elif..else construct
Cheers,
- Michal
------------------------------------------------------------------------
www.manifestation.com www.sabren.net www.linkwatcher.com www.zike.net
------------------------------------------------------------------------
More information about the Python-list
mailing list