APJ ABDUL KALAM TECHNOLOGICAL UNIVERSITY Previous Years Question Paper & Answer

Course : B.Tech

Semester : S1 and S2

Year : 2018

Term : APRIL

Branch : BIOTECHNOLOGY

Scheme : 2015 Full Time

Course Code : CS 100

Page:2





PDF Text (Beta):

17 a)

b)

b)

19
20 a)

b)
c)

2] 8)

b)

E2803 Pages: 3

What are function prototypes? Is Function prototype mandatory for every user
defined function in C? Justify your answer.

Write a C program to find the largest among three given numbers, by applying
conditional operator.

How constants are defined in C programs. Explain?

Write a C program to findsum of digits in an integer.

PART B
Answer any 4 full questions, each carries 8 marks.

For the declaration int 951, q=1, r[25]={1}, s[5][25]={{1}}; , check the validity of

the given pointer usages and if valid provide the value of the statement. Support
your answer with proper explanation.

i)*p ii) &(p+q) 111) *(&p) 1൧) *2017 v) *5]0[

What will be the output of the following code? Justify your answer.
#include

void main()

{

char s1[30]="2017 is prime",*s2;

52741;

*s2+=1;

s2+=2;

printf("\n%s",s2);}

With suitable example explain different function parameter passing methods in C.
Write a C program to find the length of a given string recursively,without using
any standard string library function.

Explain the working of loop control statements in C with examples.

What will be the output of mystery(4096,128) for the following code? Explainwhy
9

void mystery(int A, int B)

count=0;

while(A>B) { A = ^ ~ 3; countt++;}

while(B>A) { 8 = B— A; ೦೦೬೧)

printf(“%d”, count);

}
Explain switch construct with example.
What will be the output of the following code snippet?
int x=1;
switch(x)
{
case 0: printf( "Zero" );
case 1: printf( "One" );
default: printf( "Not allowed in binary" );
}
Explain with example, how break and continue constructs are useful in C
programming.
If the following code is supposed to print first 100 positive integers, which are not
multiple of 3, fill Line] and Line2 with suitable © programming statement. Justify
your answer.

Page 2 of 3

(5)

(3)

(5)

(3)

Similar Question Papers