0
1.5kviews
Structured Programming Approach : Question Paper Dec 2013 - First Year Engineering (Semester 2) | Mumbai University (MU)
1 Answer
0
0views

Structured Programming Approach - Dec 2013

First Year Engineering (Semester 2)

TOTAL MARKS: 80
TOTAL TIME: 3 HOURS
(1) Question 1 is compulsory.
(2) Attempt any three from the remaining questions.
(3) Assume data if required.
(4) Figures to the right indicate full marks.
1 (a) What do you mean by an algorithm? Which steps should you consider while developing one? (4 marks) 1 (b) Find the roots of a quadratic equation. Is the above problem definition complete? If not, make the problem definition complete.(4 marks) 1 (c) State any two functions in math.h along with their uses.(4 marks) 1 (d) What do you mean by static and auto storage class? Explain.(4 marks) 1 (e) What are the differences between the while and do..while loops?(4 marks) 2 (a) Write a program in C to cyclically rotate (left or right according to the user s choice) the elements in an array. If array a contains {1,2,3,4,5} and choice is right rotate, output should be {5,1,2,3,4}. If choice is left rotate, output should be {2,3,4,5,1}}.(10 marks) 2 (b) Write a program to generate prime numbers between 1 and 100.(10 marks) 3 (a) What do you mean by recursion? Write a program that accepts two numbers, say x and y, and calculate xy. Program should make use of recursion. If x is 3 and y is 4, then output should be 34 i.e. 81.(10 marks) 3 (b) Write a program to sort given numbers in descending order.(10 marks) 4 (a) What do you mean by a struct? What do you mean by a nested struct? A sports club wants to maintain data of its players, including name, age, no. of matches played, no. of runs, and average. For this, make a structure and comment about the size of the structure of your declaration. (10 marks) 4 (b) Write a program which will accept 2 dimensional square matrix and find out the transpose of it. Program shouldn't make use of another matrix.(10 marks) 5 (a) Write a program to generate the following patterns.
(10 marks)
5 (b) Write a program to check whether given string is a Palindrome or not.(10 marks) 6 (a) What are the different ways of parameter passing to a function? Explain with example.(10 marks) 6 (b) What do you mean by FILE? What are the different functions available to read data from the file? Specify the different modes in which files can be opened along with their syntax.(10 marks)

Please log in to add an answer.