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

UpGrad Python Practice Question

This document contains 25 questions related to programming logic and concepts. The questions cover a range of topics including arrays, strings, functions, structures, and more. They involve writing programs to accept user input, perform calculations, sort and arrange data, and more. The goal seems to be practicing and demonstrating understanding of core programming techniques and data structures.

Uploaded by

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

UpGrad Python Practice Question

This document contains 25 questions related to programming logic and concepts. The questions cover a range of topics including arrays, strings, functions, structures, and more. They involve writing programs to accept user input, perform calculations, sort and arrange data, and more. The goal seems to be practicing and demonstrating understanding of core programming techniques and data structures.

Uploaded by

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

LOGIC

UPGRADATION PROGRAM upGrad



Ques:4 Ques:9

Write a program to accept ‘n’ numbers Write a program to calculate the sum of
Progress Tracker from user , store these numbers into an first digit and last digit of a given number
array and sort the numbers of an array
using function. Ques:10
Ques:1
Ques:5 Write a program to accept a string from
Write A program to accept Four digit user , delete all vowels from the string and
number from user and count zero , odd Write a program to accept customer display the result.
and even digits from the entered number. details such as : Account_no, Name,
Balance in Acount, Assume Maximum 20 Ques:11
Ques:2 Customer In the bank. Write a function to
Write a program to accept a string value
Write a program to accept ‘n’ numbers print the account no and name of each
from the user and accept a char value
from user , store these numbers into an customer with balance below rs 100.
from the user and and find out the total
array. Find out maximum and minimum Ques:6 occurrence of char value in the string
number from an Array. value.
Write a program to accept 5 names from
Ques:3 user and store these names into an array Ques:12

Write a menu driven program that shows sort these array element in alphabetical
Write a program to accept a sentence
the working of a library. The menu option order.
from the user and reverse its each word.
should be Ques:7
Ques:13
--ADD BOOK INFORMATION Write a program to calculate the sum of
Write a program to calculate sum of
--DISPLAY BOOK INFORMATION digits of a given number.
elements of M*N matrix.

--LIST ALL BOOKS OF GIVEN AUTHOR Ques:8


Ques:14

--LIST THE COUNT OF BOOKS IN THE Write a program to swap the values of two
Write a program to accept ‘n’ numbers
LIBRARY variables using Call by Reference.
from user and store these numbers into an
array and count the number of
--EXIT occurrences of each number.

Ques:15

upGrad

LOGIC UPGRADATION PROGRAM upGrad

Write a program to calculate X(Y+Z) . Write a program to create student Ques:24
structure having fields roll_no, stud_name,
Ques:16 mark1, mark2,mark3. Calculate the total Write a program to display the
and average of marks and arrange the multiplication table of a given number.
Write a Program to Accept character and
records in decending order of marks.
display its Ascii value and its Next and Ques:25
Previous Character. Ques:22
Write a program to display whether the
Ques:17 Write a program to accept Book Details o input character is a digit or alphabet.
f’n’ books as book_title,author, publisher
Write a Program to accept ‘n’ numbers Ques:26
and cost. Assign the accession number to
and store all prime numbers in an array
each book in increasing order Display Write a program to accept basic salary
and display the array.
thease details as . from user. If basic salary>=5000 then
Ques:18 hra=15% and da=150% of basic salary.
--Book s of a specific author
Write a program to calculate the x to the If basic salary<5000 then hra=10% and
--Books by a specific publisher
power y without using Standard functions. da=110% of basic salary .
--All Books costing rs 500 and above.
Ques:19 Display the Gross salary.
All Books.
Write a program to accept three sides of a
triangle as input and print whether the Ques:23
Trangle is valid or Not.
Write a menu driven program to perform
(The trangle is valid, if sum of each of the the following operations on string using
two sides is greater then the third side.) standard library functions
--Calculate length of string
Ques:20 --Reverse a given string
Write a program to accept string from the --Concatenation of one string to another
user and replace all occurrences of
character ‘a’ by ‘*’ symbol. --Copy one String into another

Ques:21 --Compare two string.

upGrad

You might also like