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

Programming Basics

The document lists programming exercises including writing functions to calculate sums and averages, print names, compare and swap numbers, check for prime and perfect squares, and perform other basic math and string operations.

Uploaded by

vijaymuttevi
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
19 views

Programming Basics

The document lists programming exercises including writing functions to calculate sums and averages, print names, compare and swap numbers, check for prime and perfect squares, and perform other basic math and string operations.

Uploaded by

vijaymuttevi
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 1

• Write a function to calculate sum of two numbers.

• Write a program to print your name 100 times.


• Write a program to Accept Student Roll No, Marks in 3 Subjects and
print it’s Average.
• Write a program to accept Three Numbers & Print the Biggest of
Given Three Numbers
• Write a program to swap two numbers using a third variable called
temp.
• Write a program to print ODD numbers from 1 to 10
• Write a program to print natural numbers from 1 to 10 in Reverse
• Write a program to accept a string in any case and print it by
another case.
• Write a program to check whether a given number is perfect square
or not.
• Write a program to print table of any number.
• Write a program to accept a string in upper case and print it by
lower case.
• Write a program to accept any single digit number and print it in
words.
• Write a program to reverse a number
• Write a program to find largest number of a list of numbers
• Write a program to calculate and print the sum of even and odd
integers of the first n natural numbers.
• Write a program to find the area of a triangle when three sides are
given.
• Write a program to check whether a number is prime number or not
• Write a program to find sum of series 1 + 2 + 3 +......+ n for any given
n.
• Write a program to find the sum of series 12+32+52+......+n2 for any
given n.
• Write a program to print given series:1 2 4 8 16 32 64 128 for any given
n; n being count of numbers in series.
• Write a program to swap two numbers without using a third variable.
• Write a program to perform all arithmetic calculations (=, -, *, /)
using switch case.
• Write a program to find the sum of individual digits of a positive
integer.
• Write a program to the number count of letters in a given text.
• Write a program to generate square root of 1 to 10.

You might also like