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

UTA003

1) The document contains a roll number, course details, and 5 questions for a Computer Programming exam. It asks students to attempt all 5 questions about flowcharts, number systems, loops, recursion, pointers, file handling, structures, and a program to store employee details. 2) Question 1 asks about flowcharts and converting between number systems. Question 2 differentiates while and do-while loops with an example calculator program. Question 3 covers call by value, call by reference with recursion examples. Question 4 explains pointers and file handling. Question 5 differentiates structures and unions with a structure example to store employee details. 3) Students are asked to show their work, avoid cutting, and check their answer sheets by a given

Uploaded by

hepogen
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)
37 views1 page

UTA003

1) The document contains a roll number, course details, and 5 questions for a Computer Programming exam. It asks students to attempt all 5 questions about flowcharts, number systems, loops, recursion, pointers, file handling, structures, and a program to store employee details. 2) Question 1 asks about flowcharts and converting between number systems. Question 2 differentiates while and do-while loops with an example calculator program. Question 3 covers call by value, call by reference with recursion examples. Question 4 explains pointers and file handling. Question 5 differentiates structures and unions with a structure example to store employee details. 3) Students are asked to show their work, avoid cutting, and check their answer sheets by a given

Uploaded by

hepogen
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/ 1

Roll Number:

Thapar Institute of Engineering & Technology, Patiala


Department of Computer Science & Engineering
AUXILIARY EXAMINATION
BE - I Year, Semester I Course Code: UTA003
Aug 23, 2022 Course Name: Computer Programming
Time: 2 Hours M. Marks: 50
Name of Faculty: Dr Anshu Parashar

Note: Attempt all 5 questions. Assume missing data, if any, suitably. Solve all the parts of a question in order. Avoid
cutting.

Note:- Check your evaluated answer sheet before 29/08/2022.

Ql. (a) Explain the purpose of the flowchart and its different notations. Draw a flowchart for computing
the sum of 1 to 10 numbers. (6)

(b) Convert following as per mentioned number systems. (4)


I. (101101)2 =( )n)
11. (921)10 =( )16
m. (1010111100)2 =( )s
iv. (951)16 =( )8

Q2. (a) Differentiate between WHILE & DO-WHILE loops with a suitable example. (5)

(b) Write a program for a calculator that takes an arithmetic operator +, *, / & two integers
as an input and then, performs the calculation on the two operands depending upon the
operator entered by the user. (5)

Q3. (a) What do you mean by Call by value & Call by reference? Explain with suitable examples. (5)

(b) Write a program to compute the Factorial of a number using Recursion. (5)

Q4. (a) What do you mean by Pointers? Exaplain its applications through suitable example. (5)
(b) Discuss briefly file handling in C along with various file opening modes. (5)

Q5. (a) Differentiate between Structure and Union with a suitable example. (5)

(b) Write a C program using a structure i.e. EMP to store details of 05 employees. The structure should
have three members: emp name, emp_code, and emp_salary. (5)

You might also like