Download VTU ((Visvesvaraya Technological University) B.E/B-Tech 2019 July ( Bachelor of Engineering) First & Second Semester (1st Semester & 2nd Semester) 18 Scheme 18CPS13 C Programming for Problem Solving Question Paper
.
.-Aittif
iraltill111111
USN
18CPS13/23
First/Second Semester B.E. Degree Examination, June/July 2019
C Programming for Problem Solving
Time: 3 hrs. Max. Marks: 100
Note: Answer any FIVE full questions, choosing ONE full question from each module.
Module-1
0
. 1 a. With a neat block diagram of computer, explain its components. (10 Marks)
C.)
'6.. .
To b. Classify the following into input and output devices:
.
v
Monitors, visual display unit, Track balls, Bar code reader, Digital camera, Film recorder,
Microfiche, OMR, Electronic Whiteboard, Plotters. (05 Marks)
c. Define the terms: Network, LAN, WAN, MAN and network topology. (05 Marks)
cz
tfl
cl
7-7.
???
OR
1 6
2 a. Write the basic structure of C program. Explain each section briefly with suitable example.
-..,s
1
^
ti) II
(09 Marks)
cx
b. Define operator. Explain any 6 operators with suitable example.
,
(07 Marks)
.1-
c. State whether the following are valid identifiers or not: integer, float, I am, 123_AbC.
29 0
(04 Marks)
a) =
'E ?
1
-
4
^ .E
.
a Module-2
= . 3 a. De fine and write the classification of Input and Output statements in C. Write a C-program
0.) .
c
I. 1
that prints the following output:
o 4
,
-c-t.
t,
8 I am
----
._
to c
co an
,'
i
E nj;im-etY;fj
0
-0 8 SC lett,
Slucl e r4
-1
3 c,4
0
'
1
:1 at
(06 Marks)
>, tt
b. Define branching statements. Explain them with syntax and suitable example.
-:.-.
(10 Marks)
,-,-: ?
C.
Evaluate: i = 1
M. c_
.
L : if (i > 2)
,-) .
1
t
I ''a'
2
printf ("Saturday");
V
?
..,
i = i + 1; ...?. .
O
0
? 10
goto L;
CI)
o
t?-? >,
0
.F. , g)
printf ("Sunday");
6. zi Explain your result briefly. (04 Marks)
g
(5 ?
OR
--: c
,
i 4 a. State the drawback of ladder if-else. Explain how do you resolve with suitable example.
..
tu
(08 Marks)
o
z b. Write a C program to get the triangle of numbers as a result:
5 1
,
O 1 2
F--
1 2 3
1 2 3 4
(06 Marks)
c. Write a C program to check whether given number is prime or not. (06 Marks)
1 of 2
FirstRanker.com - FirstRanker's Choice
6
.
.-Aittif
iraltill111111
USN
18CPS13/23
First/Second Semester B.E. Degree Examination, June/July 2019
C Programming for Problem Solving
Time: 3 hrs. Max. Marks: 100
Note: Answer any FIVE full questions, choosing ONE full question from each module.
Module-1
0
. 1 a. With a neat block diagram of computer, explain its components. (10 Marks)
C.)
'6.. .
To b. Classify the following into input and output devices:
.
v
Monitors, visual display unit, Track balls, Bar code reader, Digital camera, Film recorder,
Microfiche, OMR, Electronic Whiteboard, Plotters. (05 Marks)
c. Define the terms: Network, LAN, WAN, MAN and network topology. (05 Marks)
cz
tfl
cl
7-7.
???
OR
1 6
2 a. Write the basic structure of C program. Explain each section briefly with suitable example.
-..,s
1
^
ti) II
(09 Marks)
cx
b. Define operator. Explain any 6 operators with suitable example.
,
(07 Marks)
.1-
c. State whether the following are valid identifiers or not: integer, float, I am, 123_AbC.
29 0
(04 Marks)
a) =
'E ?
1
-
4
^ .E
.
a Module-2
= . 3 a. De fine and write the classification of Input and Output statements in C. Write a C-program
0.) .
c
I. 1
that prints the following output:
o 4
,
-c-t.
t,
8 I am
----
._
to c
co an
,'
i
E nj;im-etY;fj
0
-0 8 SC lett,
Slucl e r4
-1
3 c,4
0
'
1
:1 at
(06 Marks)
>, tt
b. Define branching statements. Explain them with syntax and suitable example.
-:.-.
(10 Marks)
,-,-: ?
C.
Evaluate: i = 1
M. c_
.
L : if (i > 2)
,-) .
1
t
I ''a'
2
printf ("Saturday");
V
?
..,
i = i + 1; ...?. .
O
0
? 10
goto L;
CI)
o
t?-? >,
0
.F. , g)
printf ("Sunday");
6. zi Explain your result briefly. (04 Marks)
g
(5 ?
OR
--: c
,
i 4 a. State the drawback of ladder if-else. Explain how do you resolve with suitable example.
..
tu
(08 Marks)
o
z b. Write a C program to get the triangle of numbers as a result:
5 1
,
O 1 2
F--
1 2 3
1 2 3 4
(06 Marks)
c. Write a C program to check whether given number is prime or not. (06 Marks)
1 of 2
18CPS13/23
Module-3
5 a. Define an array. Explain with suitable example how do you declare and initialize ID array.
(10 Marks)
b. Write a C program to search an element using linear and binary techniques. (10 Marks)
OR
6 a. Define a string. Explain any 4 string library functions with syntax and example. (10 Marks)
b. Write a C program to copy a string (combination of digits and alphabets) to another string
(only alphabets). (10 Marks)
Module-4
7 a. Define a function. List and explain the categories of user defined functions. (10 Marks)
b. Write a C-program for evaluating the binomial coefficient using a function Factorial (n).
(10 Marks)
OR
8 a. Define a recursion. Write a C recursive function for multiplying two integers where a
function call is passed with two integers m and n. (10 Marks'
b. Differentiate: (1) User defined and built-in function (ii) Recursion and iteration (10 Marks)
Module-5
9 a. Define structures. Explain how do you declare, initialize and represent the memory for
structure variable. (10 Marks)
b. Write a C program that accepts a structure variable as a parameters to a function from a
function call. (10 Marks)
OR
10 a. Define pointers. Explain pass by value and pass by reference with C statements and an
example. (10 Marks)
b. Define pre-processor directives. Write C program that finds the addition of two squared
numbers, by defining macro for Square (x). (10 Marks)
2 of 2
FirstRanker.com - FirstRanker's Choice
This post was last modified on 01 January 2020