Uploaded by Reshi Teja

pspp exp split

advertisement
a) Write a Python program to generate Electricity Bill and develop a flow chart for the
same.
b) Develop a Python program to find the Biggest of 3 numbers using nested if...else
statement.
VivaRecord
Total
Aim, Algorithm,
Program1
Output
Voce
(10)
(100)
Flow chart,
&
&
(10)
Pseudo code
Program2
Result
(10+10)
(20 + 20)
(10+10)
a) An integer, n, is said to be perfect when the sum of all of the proper divisors of n is
equal to n. For example, 28 is a perfect number because its proper divisors are 1, 2, 4,
7 and 14, and 1 + 2 + 4 + 7 + 14 = 28.
b) Develop a Python program to find whether
using if statement.
Aim, Algorithm,
Program1
Output
Flow chart,
&
&
Pseudo code
Program2
Result
(10+10)
(20 + 20)
(10+10)
the given number is Positive or Negative
VivaVoce
(10)
Record
(10)
Total
(100)
a) Develop a Python program to read two numbers as input and Swap the Two
Numbers (using three variables).
b) Develop a Python Program to read numerator and denominator and print their
quotient and remainder.
Aim, Algorithm,
Program1
Output
VivaRecord
Total
Flow chart,
&
&
Voce
(10)
(100)
(10)
Pseudo code
Program2
Result
(10+10)
(20 + 20)
(10+10)
Page 1 of 3
a) Write a python program to get the 5 subjects marks and display the grade for the
same.
b) Develop a Python program to swap two numbers (using two variables).
Aim, Algorithm,
Flow chart,
Pseudo code
(10+10)
Program1
&
Program2
(20 + 20)
Output
&
Result
(10+10)
VivaVoce
(10)
Record
(10)
Total
(100)
a) To write a python program to find the sum of first ‘n’ natural number.
b) Write a Python program to select a random element from a list, set, dictionary (value)
and a file from a directory. Use random.choice().
Aim, Algorithm,
Program1
Output
VivaRecord
Total
Voce
(10)
(100)
Flow chart,
&
&
(10)
Pseudo code
Program2
Result
(10+10)
(20 + 20)
(10+10)
a) write a program to create, concatenate and print a string and accessing sub-string
from given string.
b) Develop a Python program to check if the given string is palindrome or not.
Aim, Algorithm,
Flow chart,
Pseudo code
(10+10)
Program1
&
Program2
(20 + 20)
Output
&
Result
(10+10)
VivaVoce
(10)
Record
(10)
Total
(100)
a) Write a Python program to get a single string from two given strings, separated by a
space and swap the first two characters of each string. Sample input: ’abc’, ’xyz’.
Expected Result : ’xyc abz’.
b) Develop a Python program to find the biggest of 3 numbers using nested if...else
statement
Aim, Algorithm,
Program1
Output
VivaRecord
Total
Voce
(10)
(100)
Flow chart,
&
&
(10)
Pseudo code
Program2
Result
(10+10)
(20 + 20)
(10+10)
a) Code a Python program create a list from given list having number and its cube in
each tuple.
b) Read two strings. Print the common characters in both the strings and the count of
them.
Aim, Algorithm,
Program1
Output
VivaRecord
Total
Voce
(10)
(100)
Flow chart,
&
&
(10)
Pseudo code
Program2
Result
(10+10)
(20 + 20)
(10+10)
a) Write a Python program to Find the Duplicate Element from a List.
b) Code a Program to Python Find the 1st,2nd Largest Element in a List.
Aim, Algorithm,
Flow chart,
Pseudo code
(10+10)
Program1
&
Program2
(20 + 20)
Output
&
Result
(10+10)
VivaVoce
(10)
Record
(10)
Total
(100)
a) Write a Python program to unpack a tuple in several variables and use + operations.
b) Write a Python program to add an item in a tuple using looping.
Aim, Algorithm,
Flow chart,
Pseudo code
(10+10)
Program1
&
Program2
(20 + 20)
Output
&
Result
(10+10)
VivaVoce
(10)
Record
(10)
Total
(100)
a) Code a Python Program to Find the Factorial of a Given Number Using Recursion.
b) Write a Python program to find the first repeated word in a given string.
Aim, Algorithm,
Flow chart,
Pseudo code
(10+10)
Program1
&
Program2
(20 + 20)
Output
&
Result
(10+10)
VivaVoce
(10)
Record
(10)
Total
(100)
a) Write a python program to remove duplicates from a list.
b) Write a python program to perform linear search
Aim, Algorithm,
Program1
Output
VivaVoce
Flow chart,
&
&
(10)
Pseudo code
Program2
Result
(10+10)
(20 + 20)
(10+10)
Record
(10)
Total
(100)
a) Code a Python program to accept a String , Reverse the String ,Check whether the
string is a Palindrome and print the result.
b) Write a Python program to Count the number of Vowels in a string.
Aim, Algorithm,
Flow chart,
Pseudo code
(10+10)
Program1
&
Program2
(20 + 20)
Output
&
Result
(10+10)
VivaVoce
(10)
Record
(10)
Total
(100)
a) Write a Python program to Find Most Frequent Words in a Text read from a File.
b) Write a Python program to find the Area of Shape.
Aim, Algorithm,
Flow chart,
Pseudo code
(10+10)
Program1
&
Program2
(20 + 20)
Output
&
Result
(10+10)
VivaVoce
(10)
Record
(10)
Total
(100)
a) Write a program that Input a Text File. The program should print all of the unique
words in the file in Alphabetical order.
b) Develop a Python program to find the average of Three Numbers.
Aim, Algorithm,
Flow chart,
Pseudo code
(10+10)
Program1
&
Program2
(20 + 20)
Output
&
Result
(10+10)
VivaVoce
(10)
Record
(10)
Total
(100)
a) Write a script named copyfile.py. This script should prompt the user for the names
of two text files. the contents of the first file should be input and written to the second
file.
b) Develop a Python program to find the Sum of Digits in an Integer using While
Statement by getting the input from the user.
Aim, Algorithm,
Flow chart,
Pseudo code
(10+10)
Program1
&
Program2
(20 + 20)
Output
&
Result
(10+10)
VivaVoce
(10)
Record
(10)
Total
(100)
a) Develop a program for Voter’s age validity. Validate using Exceptional handling
feature in python. ( Ex: age of the voter is > 18 or not).
b) Write a Python program to convert a tuple to a string.
Aim, Algorithm,
Program1
Output
VivaRecord
Total
Flow chart,
&
&
Voce
(10)
(100)
(10)
Pseudo code
Program2
Result
(10+10)
(20 + 20)
(10+10)
a) Write a python class to reverse a string word by word.
b) A prime number is an integer greater than one that is only divisible by one and itself.
Write a function that determines whether or not its parameter is prime, returning True if
it is, and False otherwise.
Aim, Algorithm,
Program1
Output
VivaRecord
Total
Voce
(10)
(100)
Flow chart,
&
&
(10)
Pseudo code
Program2
Result
(10+10)
(20 + 20)
(10+10)
a) Simulate Bouncing Ball Using Pygame
b) Write a Python program to remove Duplicates from a list.
Aim, Algorithm,
Flow chart,
Pseudo code
(10+10)
Program1
&
Program2
(20 + 20)
Output
&
Result
(10+10)
VivaVoce
(10)
Record
(10)
Total
(100)
a) Write a Python program to calculate the weight of the steel bar and develop a flow chart for
the same.
b) Write a Python program to circulate the values of n variables
Aim, Algorithm,
Flow chart,
Pseudo code
(10+10)
Program1
&
Program2
(20 + 20)
Output
&
Result
(10+10)
VivaVoce
(10)
Record
(10)
Total
(100)
a) Write a Python program to print the below Pyramid
*
**
***
****
*****
b)Write a Python program to calculate Simple Interest, Compound Interest
Aim, Algorithm,
Flow chart,
Pseudo code
(10+10)
Program1
&
Program2
(20 + 20)
Output
&
Result
(10+10)
VivaVoce
(10)
Record
(10)
Total
(100)
a) Write a Python Program to get the 5 bank customer account details with balance and print
only the customer details whose balance is greater than or equal to 10000
b) Write a python program to define a module to find Fibonacci Numbers and import the module
to another program.
Aim, Algorithm,
Flow chart,
Pseudo code
(10+10)
Program1
&
Program2
(20 + 20)
Output
&
Result
(10+10)
VivaVoce
(10)
Record
(10)
Total
(100)
a) Write a Python program that prints out the decimal equivalents of 1/2, 1/3, 1/4, . . . ,Using for
loop
b)Write a Python Program to print the Following number Pattern
55555
4444
333
22
Aim, Algorithm,
Flow chart,
Pseudo code
(10+10)
Program1
&
Program2
(20 + 20)
Output
&
Result
(10+10)
VivaVoce
(10)
Record
(10)
Total
(100)
a) Write a Python program to Remove the Duplicate Element in the Tuple
b) Write a Python script to print a dictionary where the keys are numbers between 1 and 15
and the values are square of keys
Sample Dictionary {1: 1, 2: 4, 3: 9, 4: 16, 5: 25, 6: 36, 7: 49, 8: 64, 9: 81, 10: 100, 11: 121,
12: 144, 13: 169, 14: 196, 15: 225}
Aim, Algorithm,
Flow chart,
Pseudo code
(10+10)
Program1
&
Program2
(20 + 20)
Output
&
Result
(10+10)
VivaVoce
(10)
Record
(10)
Total
(100)
a) Write a Python Program to Capitalize each word in a given String
b) Write a Python program to create a dictionary from a string and count the letters from the
string.
Sample string : ’ENGINEERING’
Expected output: {’E’: 3, ’N’: 3, ’G’: 2, ’I’: 2, ’R’: 1}
Aim, Algorithm,
Flow chart,
Pseudo code
(10+10)
Program1
&
Program2
(20 + 20)
Output
&
Result
(10+10)
VivaVoce
(10)
Record
(10)
Total
(100)
a) Write a Python Program to Calculate the Weight of the Motor Bike.
b) Write a Python Program to raise ZeroDivisionError if the User enters 0 as numerator or
Denominator value.
Aim, Algorithm,
Flow chart,
Pseudo code
(10+10)
Program1
&
Program2
(20 + 20)
Output
&
Result
(10+10)
VivaVoce
(10)
Record
(10)
Total
(100)
a) Write a Python program that accepts a comma separated sequence of words as input and
prints the unique words in sorted form.
b) Write a Python program to print the sum of first 100 odd numbers.
Aim, Algorithm,
Flow chart,
Pseudo code
(10+10)
Program1
&
Program2
(20 + 20)
Output
&
Result
(10+10)
VivaVoce
(10)
Record
(10)
Total
(100)
a) Write a python program to that accepts length of three sides of a triangle as inputs. The
program should indicate whether or not the triangle is a right angled triangle (use
Pythagorean theorem):
b) Write a Python Program to Print all Prime numbers less than 50.
Aim, Algorithm,
Flow chart,
Pseudo code
(10+10)
Program1
&
Program2
(20 + 20)
Output
&
Result
(10+10)
VivaVoce
(10)
Record
(10)
Total
(100)
a) Define a function fact and write a python Script to find the factorial of a number
b) Write a Python Program to implement the following Python tuple operation
i) Create a Tuple
ii) Find the length of the Tuple
iii) find the maximum and minimum element in the tuple
Aim, Algorithm,
Flow chart,
Pseudo code
(10+10)
Program1
&
Program2
(20 + 20)
Output
&
Result
(10+10)
VivaVoce
(10)
Record
(10)
Total
(100)
a) Write a program to create a menu with the following options
1.ADDITITON OPERATION
2. SUBSTRACTION OPERATION
3. MULTIPICATION OPERATION
4. DIVISION OPERATION
Accepts users input and perform the operation accordingly.
b) Write a Python Program to Compute Electrical current in a three Phase Electrical Circuit
Aim, Algorithm,
Flow chart,
Pseudo code
(10+10)
Program1
&
Program2
(20 + 20)
Output
&
Result
(10+10)
VivaVoce
(10)
Record
(10)
Total
(100)
a) Write a Python Program to find the Third Largest number in a given list using Functions.
b) Write a Python program to implement the following python List operation
i) Inserting the element at the specified positions
ii)Remove the element in the List
iii) Delete the entire List
iv) Position of the particular Element in a Given List
Aim, Algorithm,
Flow chart,
Pseudo code
(10+10)
.
Program1
&
Program2
(20 + 20)
Output
&
Result
(10+10)
VivaVoce
(10)
Record
(10)
Total
(100)
a) Write a Python function to reverses a string if it’s length is a multiple of 3.
b) Write a Python Program to count the number of Words present in a text file.
Aim, Algorithm,
Flow chart,
Pseudo code
(10+10)
Program1
&
Program2
(20 + 20)
Output
&
Result
(10+10)
VivaVoce
(10)
Record
(10)
Total
(100)
a) Create three text file such as “source1.txt”,”source2.txt”, in read mode , “target.txt” in write
mode and write a Python Script to copy the content of “source1.txt”,”source2.txt”, and write
the content in “target.txt file”.
b) Write a Python code to get the voters age as input. If the user Enters a Valid age as input
Display the Result otherwise Raise the Exception.
Aim, Algorithm,
Flow chart,
Pseudo code
(10+10)
Program1
&
Program2
(20 + 20)
Output
&
Result
(10+10)
VivaVoce
(10)
Record
(10)
Total
(100)
a) Create a dictionary and apply the following operations
1) Print the dictionary elements
2) Access the dictionary elements
4) Change values of the dictionary
5) Calculate the Length of the Dictionary
b) Write a Python program to display the current date and time. In the Following format. .:
2022-06-06 15:35:15.
Aim, Algorithm,
Flow chart,
Pseudo code
(10+10)
Program1
&
Program2
(20 + 20)
Output
&
Result
(10+10)
VivaVoce
(10)
Record
(10)
Total
(100)
a) Write a Python program to append text to a file and display the text in the output screen.
b) Write a Python program which accepts the user’s first and last name and print them in
reverse order with a space between them.
Aim, Algorithm,
Flow chart,
Pseudo code
(10+10)
Program1
&
Program2
(20 + 20)
Output
&
Result
(10+10)
VivaVoce
(10)
Record
(10)
Total
(100)
Record
(10)
Total
(100)
a) Develop a car race game using Pygame.
b) Write a Python Script to calculate area of a circle.
Aim, Algorithm,
Flow chart,
Pseudo code
(10+10)
Program1
&
Program2
(20 + 20)
Output
&
Result
(10+10)
VivaVoce
(10)
a) Write a NumPy program to test whether any of the elements of a given array is non-zero.
b) Write a Python program to find the longest words in a file.
Aim, Algorithm,
Flow chart,
Pseudo code
(10+10)
Program1
&
Program2
(20 + 20)
Output
&
Result
(10+10)
VivaVoce
(10)
Record
(10)
Total
(100)
a) Write the Python program To compute sin(x) using the below given Formula
sin x = x - x3/3! + x5/5! - x7/7! + x9/9! ........
b) Write a Python program to Exchange the Values of two Variables.
Aim, Algorithm,
Flow chart,
Pseudo code
(10+10)
Program1
&
Program2
(20 + 20)
Output
&
Result
(10+10)
VivaVoce
(10)
Record
(10)
Total
(100)
a) Simulate Bouncing Ball Using Pygame.
b) Write a Python Script to Check whether a given Number is odd or Even.
Aim, Algorithm,
Flow chart,
Pseudo code
(10+10)
Program1
&
Program2
(20 + 20)
Output
&
Result
(10+10)
VivaVoce
(10)
Record
(10)
Total
(100)
Download