On Wed, 06 Jun 2012 00:12:00 +0200, News123 wrote:

> If I start Python in interactive mode, and I yype the commands,
> 'a=3', 'a', 'print a'
> 
> 
> Then the  output would look like:
>  >>> a = 3
>  >>> a
> 3
>  >>>  print a
> 3
> 
> 
> Now within an application I'd like to achieve exactly this behaviour

Before you reinvent the wheel, see the cmd and code modules.

http://docs.python.org/library/cmd.html
http://docs.python.org/library/code.html



-- 
Steven
-- 
http://mail.python.org/mailman/listinfo/python-list

Reply via email to