PWP Exp2

You might also like

Download as pdf or txt
Download as pdf or txt
You are on page 1of 1

Latthe Education Society’s Polytechnic Sangli

Department of Computer Engineering

Programming with Python (PWP 22616)


Experiment NO 02

Title:- Write a simple python program to display Message On Screen.

XI. Practical Related Questions

1. List the different modes of programming in Python.


Ans:-
Python has two basic modes: script and interactive. The normal mode is the mode where
the scripted and finished .py files are run in the Python interpreter. Interactive mode is
a command line shell which gives immediate feedback for each statement, while
running previously fed statements in active memory. As new lines are fed into the
interpreter, the fed program is evaluated both in part and in whole.

2. Describe procedure to execute program using Interactive Mode.


Ans:-
Step1: Open Python command prompt by selecting py application in side Start icon.

Step2: You will see python interactive prompt, here you can execute your statements as
command

3. State the Stapes involved in executing the program using script mode.
Ans:-
Step 1: Create program using notpad and save file as .py extantion.
(File name sample.py on C:\XYZ\sample.py)
Step 2: Open command prompt go to c: Drive
Stap3:- Run Command
C:\ python c:\XYZ|sample.py

4. State the procedure to make file executable.


Ans:- We need to convert normal file into executable on linux platform.
Let’s consider file as sample.py
>> chmod u+x sample.py
Above command convert normal file into Executable.

You might also like