Informatics Practices
Record what happens when the following statements are executed:
(a) print (n = 17)
(b) print (8+9)
(c) print (4.2, "hello", 6-2, "world", 15/2.0)
Related Questions
Consider the statements given below and write Python command to display these statements in both Interactive and Script mode.
Python is easy to learn and write.
It allows us to work in two modes: Interactive mode and Script mode.
Interactive mode is also known as Python Shell and Script mode is also known as Python Editor.
It is a platform-independent language.
We find it interesting to work with Python.Write a code that prints your full name and your birthday as separate strings.
Try the following code on the Python shell and evaluate the output generated:
>>> print (3.14159*7) >>> print('I am a class XI' + 'student') >>> print('I', 'am') >>> print ("class XI student") >>> print ("I'm", 16, "years old")
Use IDLE to calculate:
(a) 6+4*10
(b) (6+4) *10