GE8161-Python lab(R2017).pdf - Google Drive

0 downloads 7 Views 422KB Size Report
Page 1 of 2. This work is licensed under a Creative Commons Attribution-NonCommercial 4.0. International License. QUESTI
QUESTION BANK GE8161 - PROBLEM SOLVING AND PYTHON PROGRAMMING LABORATORY B.E / B.TECH (ALL BRANCH) FIRST YEAR/ I SEMESTER ANNA UNIVERSITY R2017 PREPARE BY

:

Mr. BALAJI A, ASSISTANT PROFESSOR (Sr. Grade), DEPARTMENT OF COMPUTER SCIENCE & ENGINEERING, KCG COLLEGE OF TECHNOLOGY, CHENNAI – 97.

VERSION

:

1.0

RELEASED ON

:

21/12/2017 SIMPLE PYTHON PRACTICE PROGRAMS:

Use any Looping for(…) \ while() \do…while() [OR] Conditional statement if()..else.., / if().. else if()… else do the following program.. 1. Write a Python program to find the sum of ‘n’ numbers using function? 2. Write a Python program to generate the Fibonacci Series? 3. Write a Python program to calculate the Area & Circumference of Circle? 4. Write a Python program to convert Fahrenheit to Centigrade? 5. Write a Python program to swap two values without swap keyword? 6. Write a Python program to calculate Simple Interest? 7. Write a Python program to find a given number is odd or even? 8. Write a Python program to find the sum of odd and even from a set of numbers? 9. Write a Python program to find biggest of 3 numbers form a set of n numbers? 10. Write a Python program to check the given integer is prime or not? 11. Write a Python program to check and display 10 leap years? 12. Write a Python program to check the given integer is Armstrong number or not? 13. Write a Python program to generate prime numbers between 1 and 50? 14. Write a Python program to find the sum of cube of individual digits of a number? 15. Write a Python program to reverse the given number and check it is palindrome or not? 16. Write a Python program to find the roots of a quadratic equation

This work is licensed under a Creative Commons Attribution-NonCommercial 4.0 International License.

LIST PROGRAM 17. Write a Python program to find the → 2rd highest number from a set of numbers using LIST → Find the length of the list → Find the Max value in the List ---------------------------------------------------------------------------------------------------------------------SORTING / SEARCHING PROGRAM 18. Will be asked to any one python program either form sort or search ●

Bubble Sort

Merge Sort



Binary Search

Linear Search

Selection Sort

Insertion Sort

-----------------------------------------------------------------------------------------------------------------------STRING PROGRAM 19. Write a Python program to → compare two strings? → Find the length of the string? → reverse the string and check the given string is palindrome or not ----------------------------------------------------------------------------------------------------------------------SERIOUS PROGRAM 20. Write a Python program for the following serious −𝑥

+

𝑥3 3!



𝑥5 5!

21. Write a python for matrix Multiplication Program

Practice does not make perfect. Only perfect practice makes perfect. by Vince Lombardi

This work is licensed under a Creative Commons Attribution-NonCommercial 4.0 International License.