How "return" no return ?
Ximo
elrei69 at yahoo.es
Thu May 12 14:10:38 EDT 2005
I am doing my own interpreter with the Python languaje.
Do you understand me?
"Fredrik Lundh" <fredrik at pythonware.com> escribió en el mensaje
news:mailman.484.1115919541.29826.python-list at python.org...
> "Ximo" wrote:
>
>> I am doing a interpret of lines and it show me a prompt, and I want if I
>> write a declaration as "int a" my progrtam return de prompt and nothing
>> more, for exemple:
>>
>> >>> 2+2
>> 4
>> >>> int a
>> >>>
>>
>> Then I'm finding that de function which execute "int a" return me
>> nothing,
>> and no
>>
>> >>> int a
>> None
>> >>>
>
> what Python version are you using? here's what a normal Python
> interpreter is supposed to do with your example:
>
>>>> 2+2
> 4
>>>> int a
> File "<stdin>", line 1
> int a
> ^
> SyntaxError: invalid syntax
>>>>
>
> </F>
>
>
>
More information about the Python-list
mailing list