CSE110 – Department of Computer Science and Engineering Solved

$ 20.99
Category:

Description

CSE 110/162 (Programming Language I)
Lab 1

Task 1

Draw the flowchart of a program that reads one number from the user, and prints it back to show which number was entered by the user.

Task 2

Draw the flowchart of a program that reads two numbers from the user, and prints their sum, product and result of subtracting 2nd number from 1st number. For example, if user gives 5 and 7 (sequentially), the program should print 12, 35 and -2.

Task 3

Draw the flowchart of a program that reads the radius of a circle and prints its circumference and area.

Task 4

Draw the flowchart of a program that reads two numbers from the user and prints โ€œfirstโ€ if the first number is greater than the second number.

Task 5

Draw the flowchart of a program that reads two numbers from the user. Your program should then print
โ€œfirst is greaterโ€ if the first number is greater, and โ€œfirst is not greaterโ€ otherwise.

Task 6

Draw the flowchart of a program that reads two numbers from the user. Your program should then print
โ€œfirst is greaterโ€ if the first number is greater, โ€œsecond is greaterโ€ if the second number is greater, and โ€œthe numbers are equalโ€ otherwise.

Task 7

Draw the flowchart of a program that reads two numbers, and prints the absolute difference. (Hint: subtract the smaller number from the larger one).

Task 8

Draw the flowchart of a program that reads a number, and prints โ€œThe number is evenโ€ or โ€œThe number is oddโ€, depending on whether the number is even or odd. (Hint: use the modulus operator)

Task 9

Draw the flowchart of a program that prints the first ten positive whole numbers. [Do NOT use loops]

Page 1 of 2

Task 10

Draw the flowchart of a program that prints the first ten even positive whole numbers. (Do NOT use loop or modulus operator for this problem).

Task 11

Draw the flowchart of a program that reads five numbers from the user, and prints their average. [Do NOT use loops]

Task 12

Draw the flowchart of a program that finds the sum of the first 100 positive numbers. Verify your answer by calculating this sum manually. [Do NOT use loops, use the mathematical formula for calculating sum of arithmetic series]

Task 13

Draw the flowchart of a program that reads five numbers as input from the user, and prints whether the numbers are odd or even. [Do NOT use loops]

Page 2 of 2

Reviews

There are no reviews yet.

Be the first to review “CSE110 – Department of Computer Science and Engineering Solved”

Your email address will not be published. Required fields are marked *