Download JNTUA (JNTU Anantapur) B.Tech R19 (Bachelor of Technology) 1st Year 1st Semester (1-1) 2020 January 19A05101T Problem Solving And Programming Previous Question Paper || Download B-Tech 1st Year 1st Sem 19A05101T Problem Solving And Programming Question Paper || JNTU Anantapur B.Tech 1-1 Previous Question Paper || JNTU Anantapur B.Tech ME 1-1 Previous Question Paper || JNTU Anantapur B.Tech CSE 1-1 Previous Question Paper || JNTU Anantapur B.Tech Mech 1-1 Previous Question Paper || JNTU Anantapur B.Tech EEE 1-1 Previous Question Paper || JNTU Anantapur B.Tech ECE 1-1 Previous Question Paper

Code: 19A05101T

B.Tech I Year I Semester (R19) Regular Examinations January 2020

PROBLEM SOLVING & PROGRAMMING

(Common to all branches)

Time: 3 hours Max. Marks: 70

PART ? A

(Compulsory Question)

*****

1 Answer the following: (10 X 02 = 20 Marks)

(a) What is a compiler? Give an example.

(b) Write an algorithm for finding the area of a given square.

(c) List the important steps in solving a problem.

(d) Give an example showing how redundant computations make an algorithm inefficient.

(e) What is type conversion? Give an example.

(f) Illustrate the use of break in loop statements with an example.

(g) What is a command line argument? How do you pass a command line arguments to a C-program?

(h) Let int a[5] = { 1, 3, 5, 7, 9}. What is the value output of:

printf(?%d?, *(a+2)). Justify your answer.

(i) What is the use of typedef in C? Give an example.

(j) What are bit-fields? Give an example.

PART ? B

(Answer all five units, 5 X 10 = 50 Marks)

UNIT ? I

2 (a) Explain in detail about the working of a computer.

(b) Write an algorithm to compute the roots of given quadratic equation.

OR

3 Explain in detail about the strategy for designing algorithms with suitable examples wherever

necessary.

UNIT ? II

4 (a) Explain the top-down approach for problem solving.

(b) How do you measure the efficiency of an algorithm? Explain with an example.

OR

5 (a) Design an algorithm that reads a set of numbers from the user and makes a count of the number of

negative and the number of non-negative members in the set.

(b) Write an algorithm for computing the sum of all even numbers in the range 1 to n (including both

1 an n). Trace you algorithm for n = 10.

UNIT ? III

6 Explain in detail about the arithmetic, relational and logical operators in C with suitable examples.

OR

7 (a) What is function? What are the advantages of using functions in a C-program? Write C-function for

exchanging the values of two given variables.

(b) Write a C-program for computing the sum of first n terms of the following series using for loop.

S = 1 ? 3 + 7 ? 9 + 11 ? 13 + ???? ?n? terms.

Contd. in page 2

Page 1 of 2

R19

FirstRanker.com - FirstRanker's Choice

Code: 19A05101T

B.Tech I Year I Semester (R19) Regular Examinations January 2020

PROBLEM SOLVING & PROGRAMMING

(Common to all branches)

Time: 3 hours Max. Marks: 70

PART ? A

(Compulsory Question)

*****

1 Answer the following: (10 X 02 = 20 Marks)

(a) What is a compiler? Give an example.

(b) Write an algorithm for finding the area of a given square.

(c) List the important steps in solving a problem.

(d) Give an example showing how redundant computations make an algorithm inefficient.

(e) What is type conversion? Give an example.

(f) Illustrate the use of break in loop statements with an example.

(g) What is a command line argument? How do you pass a command line arguments to a C-program?

(h) Let int a[5] = { 1, 3, 5, 7, 9}. What is the value output of:

printf(?%d?, *(a+2)). Justify your answer.

(i) What is the use of typedef in C? Give an example.

(j) What are bit-fields? Give an example.

PART ? B

(Answer all five units, 5 X 10 = 50 Marks)

UNIT ? I

2 (a) Explain in detail about the working of a computer.

(b) Write an algorithm to compute the roots of given quadratic equation.

OR

3 Explain in detail about the strategy for designing algorithms with suitable examples wherever

necessary.

UNIT ? II

4 (a) Explain the top-down approach for problem solving.

(b) How do you measure the efficiency of an algorithm? Explain with an example.

OR

5 (a) Design an algorithm that reads a set of numbers from the user and makes a count of the number of

negative and the number of non-negative members in the set.

(b) Write an algorithm for computing the sum of all even numbers in the range 1 to n (including both

1 an n). Trace you algorithm for n = 10.

UNIT ? III

6 Explain in detail about the arithmetic, relational and logical operators in C with suitable examples.

OR

7 (a) What is function? What are the advantages of using functions in a C-program? Write C-function for

exchanging the values of two given variables.

(b) Write a C-program for computing the sum of first n terms of the following series using for loop.

S = 1 ? 3 + 7 ? 9 + 11 ? 13 + ???? ?n? terms.

Contd. in page 2

Page 1 of 2

R19

Code: 19A05101T

UNIT ? IV

8 Design and write algorithm for finding the square root of a given integer. Trace your algorithm for

input value 16.

OR

9 (a) What is a pointer and pointer to a pointer? Illustrate the declaration and use of pointers and pointer

to a pointer in C with suitable example program.

(b) Write an algorithm for reversing the array elements. Trace your algorithm for the following array of

size 10.

a[10] = { 12, 3, 4, 48, 87, 54, 67, 43, 78, 19 }

UNIT ? V

10 Design and write an algorithm to sort a given set of randomly ordered integers into non-descending

order using insertion method. Trace your algorithm for the following list of integers.

78 43 9 2 12 45 98 22

OR

11 (a) Explain the difference between structures and unions with the help of a C-program.

(b) Illustrate the passing of structures to functions through an example.

*****

Page 2 of 2

R19

FirstRanker.com - FirstRanker's Choice

This post was last modified on 11 September 2020