How To Exam?

a knowledge trading engine...


Gujarat Technological University 2010-2nd Sem B.E Computer Engineering , , , subject :Computer Programming and Utilization - Question Paper

Friday, 19 July 2013 11:40Web


GUJARAT TECHNOLOGICAL UNIVERSITY
B.E. Sem-II exam June- 2010
Subject code: 110003
Subject Name: Computer Programming and Utilization
Total Marks: 70

GUJARAT TECHNOLOGICAL UNIVERSITY

B.E. Sem-II Examination June- 2010

Seat No.    Enrolment No.

Subject code: 110003 Subject Name: Computer Programming and Utilization Date:17 / 06 / 2010    Time: 02.30 pm - 05.00 pm

Total Marks: 70

Instructions:

1.    Attempt all questions.

2.    Make suitable assumptions wherever necessary.

3.    Figures to the right indicate full marks.

Q.1 (a) Answer the following questions as directed    12

1.    What is infinite loop in C? How can you create it? Give an example of situation where you need to use infinite loop?

2.    Give the meaning and output of following C statements.

a.    x = 1,2,3;

b.    a = (b = 4, c = 5, b+c);

c.    if( x = 5)

printf(x is even\);

else

printf(x is odd\n);

3.    Provide two maj or differences between

a.    Software and Hardware

b.    Flowchart and Algorithm

4.    Tell whether following words represent class or object. For those words representing class, give examples of object instances and for those words representing object, name its possible class.

a.    God

b.    India

c.    Ganga

(b) Name the major components of computer and give their function in brief.    02

Q.2 (a) Write an algorithm and draw the flowchart to accept N numbers and count how 07 many of them where odd and also compute sum of all these odd.

1

A B

1    2 3

A B C D 1 2 3 4 5

OR

(b) Write a C program to display the following triangle for N lines.    07

1

A B

2    3 4 C D E F

5 6 7 8 9

Q.3 (a) Explain the following with proper syntax and examples.    08

1. Structure in C    2. Recursion

(b) Write a C program to reverse a string given from keyboard. Dont use library 06 function to reverse it.

OR

Q.3 (a) Explain the following with proper syntax and examples.    08

1. Pointers in C    2. Call by value Vs. Call by reference

(b) Write a C program to accept array of N integers and find the largest odd 06 number as well as largest even number and display them.

Q.4 (a) What is inline function in C++? Give their merits and explain them with    06

examples.

1. Array of structure 2. Static data and member function

OR

Q.4 (a) Create a C++ class for representing the point with x and y coordinates. Provide 06 member functions to read and print the point object, adding two point objects and necessary constructors.

1. Copy constructor 2. Initialization of one and two dimensional arrays in C

Q.5 (a) Explain the various I/O function with example in C.    06

(b) Write a C++ program representing the circle as class to find its area, where area 08 = PIE * radius * radius. Use it in main to create array of five circle objects, get radius for them and print the circle object with radius and area whose area is largest.

OR

Q.5 (a) What is a string? How string is stored in C? Give the various functions with 06 their use for string processing.

(b) Write a C++ program with a class having three integer data members. Provide 08 the member function along with other functions and constructors, to test whether given three number forms an Pythagorean triplet i.e. x2 + y2 = z2.

kkkkkkkkkkkkk

2







Attachment:

( 0 Votes )

Add comment


Security code
Refresh

Earning:   Approval pending.
You are here: PAPER Gujarat Technological University 2010-2nd Sem B.E Computer Engineering , , , subject :Computer Programming and Utilization - Question Paper