Python first program

Python can be executed either in command line or file program.

for command line execution you need to get in to python environment, for that need to open your terminal and type python, then you will get in to python environment.
We will print string "Hello World" using python, for that you need to type print "Hello World" . This will print Hello World 

 for exiting from python environment press ctrl+d in pc.

or you can execute through as file program for that , open you text editor and type print "Hello World"   and save it as . for example , for running you need to type python      and hit enter.


No comments:

Post a Comment


installing perl dancer in ubuntu

For installing perl dancer you need curl utility for installing curl ,   sudo apt-get install curl Now we can install Perl-Dancer by thi...