Bachelors Level/First Year/First Semester/Science bit/first semester/c programming/syllabus wise questions

Bachelors In Information Technology

Institute of Science and Technology, TU

C Programming (BIT102)

Year Asked: 2081.2, syllabus wise question

Arrays and Strings
1.
List any five types of functions for string manipulation with their uses. [5]
2.
Write a program to add two 3×3 matrices. [5]
Control Structures
1.
Define odd loop. What do you mean by goto and label? Write a program to generate the following pattern.
11
222 2
3333 3 3
44444 4 4 4
[10]
2.
Write an algorithm and flowchart to test whether the given integer is odd or even. [5]
3.
Differentiate between switch statement and if else if ladder. [5]
Elements of C
1.
Define token. Describe any three types of statements. [5]
Functions
1.
When do we need external function? Illustrate the process of swapping the value of two variables using the concept of pass by value and pass by reference. [3+7]
Operators and Expressions
1.
What is the task of sizeof and comma operator? Discuss about type conversion. [5]
2.
Give any two types of logical operators. What are formatted and unformatted I/O means? [5]
Structure and Unions
1.
Differentiate between fgets() and fgetc(). What is the task of typedef? Write a program to define a structure Book with data members name, price and author. Display the names of the book having price greater than 1000. [10]
2.
What is union? Differentiate between pointer and array. [5]
The C Preprocessor
1.
Define pre-processor. How do you pass pointer as argument? [5]