This download link is referred from the post: JNTU Anantapur B-Tech 1-1 last 10 year question papers 2010 -2020 -All regulation- All branches- 1st Year 1st Sem
Firstranker's choice
Code: 15A05101
--- Content provided by FirstRanker.com ---
B.Tech I Year I Semester (R15) Supplementary Examinations November/December 2019
COMPUTER PROGRAMMING
(Common to CE, EEE, CSE, ECE, ME, EIE and IT)
Time: 3 hours
Max. Marks: 70
--- Content provided by FirstRanker.com ---
PART - A
(Compulsory Question)
*****
- Answer the following: (10 X 02 = 20 Marks)
- Describe in one or two sentences about the phases in software development.
- Draw a flow chart for finding the second maximum number in a set of three given integers.
- If the base address of a two dimensional integer array A with 10 rows and 10 columns is 1100, find the address of the following elements. Size of integer is 2 bytes.
- A[5][7].
- A[0][0].
- A[9][1].
- A[7][7].
- Illustrate the use of break statement with suitable code snippet.
- Write a C function to interchange two values using pointers.
- What is a type qualifier? What is its use? Give one example.
- What is an enumerated data type? Give an example.
- Give example for declaring and accessing bit fields.
- What do you mean by formatted I/O? Give an example.
- Write a C function to read two strings, compare them and print the result.
--- Content provided by FirstRanker.com ---
--- Content provided by FirstRanker.com ---
--- Content provided by FirstRanker.com ---
PART - B
(Answer all five units, 5 X 10 = 50 Marks)
--- Content provided by FirstRanker.com ---
UNIT - I
- (a) Illustrate the working of bitwise operators in C.
(b) Write an algorithm and draw flow chart for computing the GCD of two given integers. - Explain in detail about the data types in C.
UNIT - II
--- Content provided by FirstRanker.com ---
- (a) Write a C program for calculating the sum of first 'N' odd numbers using for loop.
(b) Write a C function that takes a single dimensional integer array as input and prints the largest number among the elements of the array. Access the elements of the array using pointer arithmetic.OR
- (a) Write a C program for computing the sum of first 'n' terms of the following series using for loop.
1 + 1/x² + 1/x³ + 1/x⁴ + ...--- Content provided by FirstRanker.com ---
(b) Explain the syntax and use of switch statement with suitable example.
UNIT - III
- (a) Write a C function countEven(int*, int) which receives an integer array and its size, and returns the number of even numbers in the array.
(b) Write a brief note on storage classes in C.OR
- (a) Write a C program to declare memory for an array of integers dynamically and initialize the array with -1.
(b) Illustrate the scope of variables in C with suitable example.
--- Content provided by FirstRanker.com ---
UNIT - IV
- (a) Write a C program to determine mean and grade based on mean of the marks obtained by the students in three subjects. Grade is defined in below table.
Mean Grade 90 <= x <= 100 A+ 80 <= x < 90 A 70 <= x < 80 B 60 <= x < 70 C x < 60 D --- Content provided by FirstRanker.com ---
(b) Illustrate the use of typedef with suitable example.OR
- Provide an implementation of a function POINTshow(struct Rect, struct Point) that returns the position of the point with respect to the rectangle (i.e. Inside, outside or on). The rectangle corner points are stored in the structure Rect and the point coordinates are stored in a structure Point. Assume that the rectangle sides are parallel to the x and y axes.
UNIT - V
- Write a C program to read a text file and print the following information. Provide the name of the file to read as command line argument:
- Total number of characters.
- Total number of lines.
- Total number of vowels and consonants.
- Total number of words.
--- Content provided by FirstRanker.com ---
OR
- Explain the following library functions with suitable examples:
- fopen.
- fread.
- fseek.
- fscanf.
- fprintf.
--- Content provided by FirstRanker.com ---
--- Content provided by FirstRanker.com ---
*****
--- Content provided by FirstRanker.com ---
This download link is referred from the post: JNTU Anantapur B-Tech 1-1 last 10 year question papers 2010 -2020 -All regulation- All branches- 1st Year 1st Sem