osdir.com


[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Aw: Re: Re: Re: stuck on time


> >> In an interactive interpreter:
> >>
> >> def print_time():
> >> 	  current_time = time.strftime("%I:%M")
> >
> > What happens if you then do
> >
> > print_time()
> >
>
> print_time()
> on it's own returns NameError: name 'print_time' is not defined

Notice the "then" above ?

More precisely: directly one after the other without leaving the interpreter ...

Karsten