0% found this document useful (0 votes)
4 views1 page

Basic Python 20 Questions

The document lists 20 basic Python practice questions aimed at beginners. These questions cover fundamental programming concepts such as input/output, arithmetic operations, control structures, string manipulation, and list operations. Each question encourages the user to write a specific Python program to enhance their coding skills.

Uploaded by

mohitdeoreboris
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)
4 views1 page

Basic Python 20 Questions

The document lists 20 basic Python practice questions aimed at beginners. These questions cover fundamental programming concepts such as input/output, arithmetic operations, control structures, string manipulation, and list operations. Each question encourages the user to write a specific Python program to enhance their coding skills.

Uploaded by

mohitdeoreboris
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

20 Basic Python Practice Questions

1 Write a Python program to print 'Hello, World!'.


2 Write a program to take a number as input and print it.
3 Write a program to add two numbers entered by the user.
4 Write a program to check if a number is even or odd.
5 Write a program to check if a number is positive, negative, or zero.
6 Write a program to find the largest of three numbers.
7 Write a program to check if a year is a leap year.
8 Write a program to print numbers from 1 to 10 using a loop.
9 Write a program to print the multiplication table of a number.
10 Write a program to find the sum of numbers from 1 to n.
11 Write a program to calculate the factorial of a number.
12 Write a program to reverse a string.
13 Write a program to check if a string is a palindrome.
14 Write a program to count vowels in a string.
15 Write a program to find the largest element in a list.
16 Write a program to find the sum of all elements in a list.
17 Write a program to remove duplicates from a list.
18 Write a function to add two numbers and return the result.
19 Write a function to check if a number is prime.
20 Write a function to calculate the square of a number.

You might also like