JNTU

JNTU B.Tech I Year PROGRAMMING FOR PROBLEM SOLVING Previous Question Paper (December – 2018 - R18)

B.Tech | I Year | I Semester | R18 | December – 2018

Answer PaperPaper Code: 151ACMaximum Marks: 75Time: 3 hours

Part A is compulsory which carries 25 marks. Answer all questions in Part A. Part B consists of 5 Units. Answer any one full question from each unit. Each question carries 10 marks and may have a, b, c as sub questions.

Part A

125 marks
a

What is a flowchart? Explain with one example.

2 marks

Answer

A flowchart is a graphical representation of an algorithm or process using standard symbols like ovals for start/end, parallelograms for input/output, and rectangles for processing. For example, a flowchart to find the sum of two numbers would start, accept two inputs, add them using a process box, display the result, and stop.

b

Discuss about Strlen() function with an example.

2 marks

Answer

The strlen() function, defined in <string.h>, calculates the length of a string excluding the null terminator. Example: int len = strlen("Hello"); returns 5.

c

Explain fseek() function with example.

2 marks

Answer

Sign in to view the complete answer paper.

d

Explain about the parameter passing using copy by address.

2 marks

Answer

Sign in to view the complete answer paper.

e

Write an algorithm to find the given number is prime or not.

2 marks

Answer

Sign in to view the complete answer paper.

f

C is a structured programming language? Justify.

3 marks

Answer

Sign in to view the complete answer paper.

g

How pointer can be used for accessing multi dimensional arrays? Discuss.

3 marks

Answer

Sign in to view the complete answer paper.

h

Name few preprocessor directives.

3 marks

Answer

Sign in to view the complete answer paper.

i

Write Recursive function for towers of honoi.

3 marks

Answer

Sign in to view the complete answer paper.

j

Find out no. of comparisons to sort {2,1,7,4,8,6}.

3 marks

Answer

Sign in to view the complete answer paper.

Part B

210 marks
a

Describe the various control structures available in ‘C’.

5 marks

Answer

Sign in to view the complete answer paper.

b

Write a program to find whether the given no is am strong or not.

5 marks

Answer

Sign in to view the complete answer paper.

OR
310 marks
a

Explain about different bit-wise operators with examples.

5 marks

Answer

Sign in to view the complete answer paper.

b

What are command line arguments? Explain with a complete ‘C’ program.

5 marks

Answer

Sign in to view the complete answer paper.

410 marks
a

Explain about Enumerated data types with an example.

5 marks

Answer

Sign in to view the complete answer paper.

b

Consider the array declaration: float a[5]; and the memory address of a[0] is 4056. What is the memory address of a[2]?

5 marks

Answer

Sign in to view the complete answer paper.

OR
510 marks
a

What is a structure? Explain how to declare, initialize and access the structure elements.

5 marks

Answer

Sign in to view the complete answer paper.

b

Write a program to find the string length by using string function.

5 marks

Answer

Sign in to view the complete answer paper.

610 marks
a

What is a file pointer? Explain the steps for sequential file operations.

5 marks

Answer

Sign in to view the complete answer paper.

b

Compare gets() and fgets() with an example.

5 marks

Answer

Sign in to view the complete answer paper.

OR
710 marks
a

Write a program to copy the contents of one file to another file.

5 marks

Answer

Sign in to view the complete answer paper.

b

List and define the preprocessor statements in C.

5 marks

Answer

Sign in to view the complete answer paper.

810 marks
a

What is a function prototype? Give an example.

5 marks

Answer

Sign in to view the complete answer paper.

b

Explain about different parameter passing mechanisms with examples.

5 marks

Answer

Sign in to view the complete answer paper.

OR
910 marks
a

Define Recursion. Write a recursive function for swapping of two numbers .

5 marks

Answer

Sign in to view the complete answer paper.

b

Write a program for printing Fibonacci series by using Recursive function.

5 marks

Answer

Sign in to view the complete answer paper.

1010 marks
a

Apply linear search on {22,11,66,44,99,55,88}.

5 marks

Answer

Sign in to view the complete answer paper.

b

Apply bubble sort on the above given data.

5 marks

Answer

Sign in to view the complete answer paper.

OR
1110 marks
a

What do you mean by sorting? Mention the different types of sorting.

5 marks

Answer

Sign in to view the complete answer paper.

b

Explain quick sort in detail on {24,12,11,76,39,12,67,34,88,91,26,45,78}.

5 marks

Answer

Sign in to view the complete answer paper.

About this paper

This page contains the solved question paper with answers of PROGRAMMING FOR PROBLEM SOLVING from JNTU for B.Tech AE I Year I Semester, December – 2018, R18.

For the question paper without answers, switch to the Question Paper tab.

Other papers in PROGRAMMING FOR PROBLEM SOLVING

Loading Question Papers

Fetching data from database...