http://www.makaut.
com
Name : ……………………………………………………………
Roll No. : ………………………………………………………...
Invigilator's Signature : ……………………………………….
CS/BCA/SEM-1/BCA-103/2012-13
2012
INTRODUCTION TO PROGRAMMING
Time Allotted : 3 Hours Full Marks : 70
The figures in the margin indicate full marks.
Candidates are required to give their answers in their own words
as far as practicable.
GROUP – A
( Multiple Choice Type Questions )
1. Choose the correct alternatives for any ten of the following :
10 1 = 10
i) C is a
a) middle level language
b) high-level language
c) low-level language
d) none of these.
ii) A do-while loop is useful when we want that the
statements within the loop must be executed
a) only once b) at least once
c) more than once d) none of these.
1107 [ Turn over
CS/BCA/SEM-1/BCA-103/2012-13
iii) Every C function
a) by default return an integer value
b) by default return more than one integer value
c) by default return an floating costant
d) none of these.
iv) An array is a collection of
a) different data types scattered through memory
b) the same data type scattered throughout the
memory
c) the same data type placed next to each other in
memory
d) different data types placed next to each other in
memory.
v) When you pass an array as an argument to a function,
what actually gets passed
a) address of the array
b) value of the elements of the array
c) address of the first element of the array
d) number of elements of the array.
1107 2
CS/BCA/SEM-1/BCA-103/2012-13
vi) What is a preprocessor directive ?
a) A message from compiler to the programmer
b) A message from compiler to the linker
c) A message from programmer to the preprocessor
d) A Message from programmer to the
microprocessor.
vii) A header file is
a) a file that contains standard library functions
b) a file that contains definitions & macros
c) a file that contains user defined functions
d) a file that is present in current working directory.
viii) The break statement is used to exit from
a) an if statement
b) a for loop
c) a program
d) the main () function.
1107 3 [ Turn over
CS/BCA/SEM-1/BCA-103/2012-13
ix) Which function would you use if a single key is to be
received through the keyboard ?
a) scanf() b) gets()
c) getcha() d) getchar().
x) If p & q are two pointer variables, then which of the
following statements are true
a) p+ q b) p/ q
c) p + 10 d) none of these.
xi) What is the output of the following programs ?
main()
{ int i = 1
printf("%d%d%", i, ++i, i++ );
a) 1 3 3 b) 3 2 2
c) 3 1 1 d) 3 3 1.
1107 4
CS/BCA/SEM-1/BCA-103/2012-13
GROUP – B
( Short Answer Type Questions )
Answer any three of the following. 3 5 = 15
2. Describe the different symbols used in a flowchart with a
suitable example. What do you mean by debugging of a
program ? 4+1
3. Briefly describe the different loop control structures in 'C'
with syntax, example and explanation.
4. What are the advantages of using functions in 'C'
programming ? What is the difference between users
defined functions & library functions ? What is recursion in
programming ? What advantage is there in its use ?
2+1+1+1
5. What is dynamic memory allocation ? Why a linked list is
called a dynamic data structure ? What are the advantages
of using linked lists over arrays ? 1+2+2
6. What is structure ? How is a structure member accessed ?
What is an array of structures described with an example ?
1+1+3
1107 5 [ Turn over
CS/BCA/SEM-1/BCA-103/2012-13
GROUP – C
( Long Answer Type Questions )
Answer any three of the following. 3 15 = 45
7. Explain the difference between 'call by reference' and 'call by
value'. What is the difference between global & local
variable. Write a recursive function for GCD calculation.
5+3+7
8. What do you mean by storage classes in 'C' ? Name different
storage classes and explain each with examples. Write a 'C'
program that implements the matrix multiplication using 2-D
array. 2+6+7
9. What is linked list ? What are the advantages of switch
case ? Describe different types of data types. Write a 'C'
program to calculate factorial of a number. 2+2+6+5
10. What is union ? How does a union differ from a structure ?
How a union member accessed ? Write a 'C' program that
implements a structure person that would contain person
name, data_of_joining & salary. 2+3+2+8
1107 6
CS/BCA/SEM-1/BCA-103/2012-13
11. Write short notes on any three of the following : 3 5
a) Preprocessor directives
b) strcpy() and strcm () function
c) Automatic and satic variables
d) getc() and getchar() function
e) Actual & formal arguments.
1107 7 [ Turn over