You are on page 1of 1

Raksha Shakti University, Ahmedabad

Bachelor of Technology in Computer Science & Engineering (B.Tech. in C.S. & E.)
End Semester – I Examination December-2017
Date: 26/12/2017 Paper Code: BCS104 Time: 10.30 to 13.30
Total Section I to II Subject: Introduction to Computer Programming Total Marks : 70
Exam Seat Number:

Section-I
Q. 1 Give the short answer (Any Five) (05*03=15)
1 Explain the (? Ternary) and Size of operators with proper examples.
2 Explain the use of break statement with example.
3 What do you mean by local and global variables? Give their scope and life time and compare them.
4 Write a function which accepts a string and returns the length of the string.
5 List the various in-built string functions with example (at least three).
6 Define the union.
Q. 2 Give the long answer (Any Four) (04*05=20)
1 Explain the multiple (ladder) if-else with syntax and proper example
2 Assume that you want to make the sum of 1 to 100. Give the necessary code to perform the same using
(1) For loop (2) While loop (3) Do-while loop
3 What are the logical operators in C? List and explain them.
4 Write a program to find the minimum value from the array of 3x3.
5 State the difference between call by value and call by reference with example
Section-II
Q. 3 Give the short answer (Any Five) (05*03=15)
1 What is pointer? Explain it with example.
2 What is array? Explain with example.
3 Write a program to find factorial of given number using recursion
4 What is structure? Define the structure and explain how to access the structure members.
5 Explain C tokens with examples
6 Write a C program to find out Armstrong Numbers between 0 and 999.
Example : 153 is an Armstrong number because 13+53+33=153
Q. 4 Give the long answer (Any Four) (04*05=20)
1 What is function? Explain the function definition, function prototype and function call with example.
2 Write a program which accepts a long string and print only characters at positions which are multiple of 3
3 What is dynamic memory allocation? What is difference between malloc and calloc ?
4 What is file management? List the different file management functions and explain the various file modes.
5 Write a program to display the contents of a given file.

You might also like