0% found this document useful (0 votes)
1 views

python practical prog

The document outlines practical Python programming exercises, including input/output operations, number comparisons, pattern generation, and series calculations. It also covers concepts such as perfect numbers, prime checking, Fibonacci series, and string manipulations. Additionally, it includes tasks for working with lists, tuples, and dictionaries.
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
1 views

python practical prog

The document outlines practical Python programming exercises, including input/output operations, number comparisons, pattern generation, and series calculations. It also covers concepts such as perfect numbers, prime checking, Fibonacci series, and string manipulations. Additionally, it includes tasks for working with lists, tuples, and dictionaries.
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 1

Practical of Python Programs

1. Input a welcome message and display it.


2. Input two numbers and display the larger / smaller number.
3. Input three numbers and display the largest / smallest number.
4. Generate the following patterns using nested loops:
* 12345 A
** 1234 A B
*** 123 A B C
**** 12 A B C D
***** 1 A B C D E

5. Write a program to input the value of x and n and print the sum of the
following series:
6. Determine whether a number is a perfect number, an Armstrong number or a
palindrome.
7. Input a number and check if the number is a prime or composite number.
8. Display the terms of a Fibonacci series.
9. Compute the greatest common divisor and least common multiple of two
integers.
10. Count and display the number of vowels, consonants, uppercase,
lowercase characters in string.
11. Input a string and determine whether it is a palindrome or not; convert
the case of characters in a string.
12. Find the largest/smallest number in a list/tuple
13. Input a list of numbers and swap elements at the even location with the
elements at the odd location.
14. Input a list/tuple of elements, search for a given element in the list/tuple.
15. Create a dictionary with the roll number, name and marks of n students
in a class and display the names of students who have marks above 75.
16. Write a random number generator that generates random numbers
between 1 and 6 (simulates a dice).

You might also like

pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy