Important Questions
Important Questions
Demonstrate with example print (), input (), keyword, string concatenation and replication.
What are Python datatypes and expressions? Explain with examples for each.
Write program to convert different datatypes.
Explain elif, for, while, break and continue statements in python with examples for each.
List and explain various flow control statements used in Python with an example.
What are user defined functions? Explain how to define functions with suitable example.
Explain with example local and global variables.
What is a List? Explain append (), insert (), remove () methods.
Write a Python program that performs the following operations on a list of strings: i) create a
list called student name with N items ii) append two names iii) remove the student name
indexed at 3 iv) Print all the items in name list using a for loop.
What are mutable and immutable data.
Write a program to convert the list with 10 numbers as items into tuple and demonstrate i)
indexing of first, middle and last item ii) slicing of tuple to create subset of numbers from 3 to
6
Describe python language support for arithmetic operators. Write a python program to
calculate Student result based on 2 exams. I sport event and 3actives conducted in a collage
with weightage of the activity 20 and sport 20 for 50 marks.
Write a Python program i) to find the largest of three numbers ii) Check whether the given
year is leap year or not with functions.
Develop a program to generate Fibonacci square of length (N). Read N from console.