0% found this document useful (0 votes)
11 views2 pages

Fundamental of Programming - 24-10-2018

Uploaded by

Soumya Das
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
11 views2 pages

Fundamental of Programming - 24-10-2018

Uploaded by

Soumya Das
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 2

Seat No:______________ Enrollment No:______________

PARUL UNIVERSITY
FACULTY OF IT & COMPUTER SCIENCE
BCA/IMCAWinter2018–19 Examination
Semester: 01 Date: 24/10/2018
Subject Code: 05101102 Time:10:30 am to 01:00 pm
Subject Name: Fundamentals of Programming Total Marks: 60

Instructions:
1. All questions are compulsory.
2. Figures to the right indicate full marks.
3. Make suitable assumptions wherever necessary.
4. Start new question on new page.

Q.1 Answer the following. [15]


(a) 1. Define Program. [5]
2. What is Global Variable?
3. Write down types of macros.
4. Array index always start from __________ index value.
5. How to declare an array?
(b) 1. Which of the following is not a valid C variable name? [10]
A) int number; B) float rate;
C) int variable_count; D) int $main;
2. Input/output function prototypes and macros are defined in which header file?
A) conio.h B) stdlib.h
C) stdio.h D) dos.h

3. Break statement is used for


A) Quit a program B) Quit the current iteration
A. C) Both of above D)None of above
B.
4. The keywords cannot be used as variable names.
A)True B) False

5. A non-zero value is considered to be false and a zero value is considered to be true.


A)True B) False

6. Which Header file is required for the exit() statement?


A) conio.h B) stdlib.h
C) stdio.h D) dos.h

7. What is the size of an int data type?

A)4 Bytes B) Depends on the System/Complier


C) 8 Bytes D) None of these

8. What is the output of this C code?


#include<stdio.h>
int main(){
int i=10, j=3, k=3;
printf(“%d %d %d”, i,j,k);
}
A) Compile time Error B) 10 3 3
C) 10 3 D) None of these

9. Array is used for _____________data type of element.

A) Homogeneous B) Similar
C) (A) and (B) both D) None of this

10. What is the index number of the last element of an array with 29 elements?
A) 29 B) 28
C) 0 D) Programmer-defined

Q.2 Answer the following. (Attempt any FIVE). [15]


1. Difference between complier and interpreter
2. What are the differences between while loop and do while loop?
3. Define Variable, Keyword and token.
4. What is constant? What are the different types of constant? Explain any one in brief.
5. What is storage class? What are the different storage classes in C? Explain any one with
suitable example.
6. What is Flowchart? Draw a flowchart for swapping of two numbers.

Q.3 Attempt any THREE. [15]


1. What is data type explain any four data types used in C language. [5]
2. Write a C Program to print half pyramid as using * as shown in figure below with output. [5]

*
**
***
****
*****
3. Write down C Program to Check whether a number is palindrome or not. [5]
4. Explain decision making control statements in C language with Example. [5]

Q.4 Answer the following. [15]


(a) Explain structure of C with example. [5]
(b) Explain one dimensional array and two Dimensional array with an example. Write pros and cons of [10]
array.
OR
(b) List out operator supported by C programming. Explain any three in detail. [10]

You might also like