python sandbox question

2012-05-03 Thread viral shah
Hi Can anyone answer these two questions : I have two questions regarding Pysandbox: 1.) How do I achieve the functionality of eval? I understand sandbox.execute() is equivalent to exec, but I can't find anything such that if the code entered were 2 + 2, then it would return 4, or something to t

Code help for understand

2012-05-02 Thread viral shah
Hi in every .py file I found this same code line on the below side *def main(): application = webapp.WSGIApplication([('/', MainHandler)], debug=True) run_wsgi_app(application) if __name__ == '__main__': main() * can anyone explain me what's

For loop

2012-04-30 Thread viral shah
Hi I want to make a pattern like this *1 22 333 5 * and I did the following code, *for i in range (5): for j in range (i): print i print " "* got the output : * * *1 2 2 3 3 3 4 4 4 4* What's I'm not doing right, please let me know about this -- http://mail.python.org/ma

help

2012-04-29 Thread viral shah
I want to print below matrix. can any one suggest me the method for the same 1 2 3 4 5 6 7 8 9 Thanks -- Viral Shah IT Department, E-mail : [email protected] Mobile : (+91) 9722312220 -- http://mail.python.org/mailman/listinfo/python

Set Date and Time on Python

2012-04-26 Thread viral shah
Hi I'm very new to Python programming. Please help me to add date and time ! Following is the code done by me. import datetime class Module type(datetime.datetime) Now what's the next to do for displaying date and time ? -- http://mail.python.org/mailman/listinfo/python-list