XI-IP-II-Getting Started With Python-Module II-07-05-2021
XI-IP-II-Getting Started With Python-Module II-07-05-2021
Spyder is a powerful interactive development environment for the Python language with advanced
editing , interactive testing ,debugging and introspection features. Spyder IDE is the most preferred choice.
It comes preloaded with Anaconda distribution.
Spyder Interface:
Once the spyder is loaded,you will see following interface:
Page 1 of 9
Page 2 of 9
The python console takes commands in front of In[ ] and often shows output with Out[ ] lines.
Interactive mode:
To work in interactive mode in Spyder IDE ,type your command(s) in IPython console pane of spyder
window. It will give you the output of the command there itself. See fig. above where we type command;
print(“Hello”)
Page 3 of 9
Script Mode:
To work in script mode in Spyder IDE, type your script’s commands in the editor pane.
Page 4 of 9
Please make sure to select file type as Python Files.
Page 5 of 9
After typing the script(save it),you can run your script by:
Page 6 of 9
PyScripter IDE-another Popular IDE:
There is another free and open source IDE can be used for writing and executing Python programs.Its
interface looks like as shown below. For interactive mode ,type directly commands in console window and
for script mode ,can write script in editor pane and then run it by pressing Run icon or through Run menu.
Page 7 of 9
Now you are familiar with different ways of working with Python, we can begin with our simple statement
ofprogram.
Understanding print( )
For Example:
it will print:
Hello Class XI
Now type:
it will print
Explanation:
Carefully notice that first string is enclosed in double quotes and second in single quotes. Both the strings
are valid,but just ensure that opening and closing quotation mark should be of same type.
Page 8 of 9
Assignment question:
2. Python is free and open source. What do you mean by this statement?
#print(“such as”)
Page 9 of 9