[go: up one dir, main page]

0% found this document useful (0 votes)
7 views2 pages

Class Xi A - Cs Holiday Homework

The document outlines holiday homework for Class XI A in Computer Science at PM SHRI Kendriya Vidyalaya No2 Tambaram, focusing on fundamental Python concepts. It includes exercises on basic programming, conditional statements, loops, strings, and lists, with specific tasks such as temperature conversion, calculator creation, and palindrome checking. Each section contains multiple programming assignments aimed at enhancing students' coding skills in Python.

Uploaded by

nigandhaniniya
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)
7 views2 pages

Class Xi A - Cs Holiday Homework

The document outlines holiday homework for Class XI A in Computer Science at PM SHRI Kendriya Vidyalaya No2 Tambaram, focusing on fundamental Python concepts. It includes exercises on basic programming, conditional statements, loops, strings, and lists, with specific tasks such as temperature conversion, calculator creation, and palindrome checking. Each section contains multiple programming assignments aimed at enhancing students' coding skills in Python.

Uploaded by

nigandhaniniya
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/ 2

PM SHRI KENDRIYA VIDYALAYA NO2 TAMBARAM

HOLIDAY HOMEWORK
SUB: COMPUTER SCIENCE
CLASS :XI A

The exercises cover fundamental Python concepts such as loops, conditionals, strings, and list.

1. Basic Python Programs

1. Temperature Conversion Write a Python program to convert temperatures from


Celsius to Fahrenheit and vice versa.

2. Calculator Create a simple calculator that performs addition, subtraction,


multiplication, and division based on the user’s choice.

3. Even Numbers Between a Range Write a Python program to print all even numbers
between 1 and 50.

4. Swapping Two Numbers Write a program to swap the values of two variables without
using a third variable.

5. Leap Year Check: Write a program to check if a given year is a leap year.

2. Conditional Statements

1. Check Odd or Even Write a program to check whether a number entered by the user is
odd or even.

2. Largest of Three Numbers Write a Python program to input three numbers and print
the largest of the three.

3. Grading System Input a student’s percentage and display their grade based on the
following:
• 90% and above: A
• 80% - 89%: B
• 70% - 79%: C
• 60% - 69%: D
• Below 60%: Fail

3. Loops

1. Print Natural Numbers Write a program to print the first 20 natural numbers using a for
loop.

2. Multiplication Table Write a Python program to display the multiplication table of any
number entered by the user.

3. Factorial of a Number Write a program to calculate the factorial of a given number


using a while loop.
4. Sum of Digits Write a program to input a number and calculate the sum of its digits.

5. Prime Number Check Write a Python program to check if a number entered by the
user is a prime number.

6.Pattern Printing Write a program to display the following pattern:

* *

* * *

* * * *

* * * * *

4. Strings

1. Palindrome Check Write a program to check if a given string is a palindrome (reads the
same forward and backward).

2. Count Vowels and Consonants Write a Python program to count the number of vowels
and consonants in a given string.

3. Word Count Write a Python program to count the number of words in a sentence
entered by the user.

4. Reverse a String Write a program to reverse a string without using built-in functions

5. Lists

1. Find the Largest Element Write a program to input a list of numbers and find the
largest element in the list.

2. List Reversal Write a Python program to reverse a list without using the built-in
reverse() method.

3. Sum of List Elements Write a program to calculate the sum of all the elements in a list.

4. Fibonacci Series: Write a program to generate the first n terms of the Fibonacci
series.

5. Check Prime Number: Write a program to check if a given number is a prime number.

6. Armstrong Number: Write a program to check if a number is an Armstrong number

**************************

You might also like