Reg.
No:
SNS College of Technology, Coimbatore-35.
(Autonomous)
B.E/B.Tech- Internal Assessment -I
Academic Year 2024-2025(Even)
First Semester
B
23ITT101 – PROGRAMMING IN C AND DATA STRUCTURES
Time: 11/2 Hours Maximum Marks: 50
Answer All Questions
PART-A (5 x 2 = 10 Marks)
1. List out some of the input and output devices CO1 Rem
2. Whether = and = = are equal justify? with example CO1 Ana
3. What will be the output of the following C code? CO1 Ana
#include<stdio.h>
int main() {
int x = 10;
char y = 'a';
printf("The size of int is: %d\n", sizeof(x));
printf("The size of char is %d\n", sizeof(y));
return 0;}
4. What is the output of the program? CO2 Ana
int main()
{
int i = 20;
if (i < 15) {
printf("i is smaller than 15");
}
else {
printf("i is greater than 15");
}
return 0;
}
5. Write the syntax of ‘for’ loop. CO2 Rem
PART–B (13+13+14=40 Marks)
6. (a) Describe the various building blocks of a computer in detail with 13 CO1 Und
neat sketch and example for each category
(or)
(b) (i)Draw a flow chart to verify user in ATM machine (8) CO1 Ana
(ii)Draw a flow chart to calculate largest of 3 numbers. (5) CO1 Ana
7. (a) Write a C program to get student marks in three subjects. Find out 13 CO2 App
the Percentage of mark and average mark in three subjects. Based
on the percentage of the student in three subjects,
calculate the grade using this range
i)80 or above A grade ii)60 or above B grade iii)40 or above C
grade
iv)39 or less Fail (or)
(b) (i)Write a C program to check whether the candidate is Eligible for (8) CO2 App
voting or not
(ii) Write a C program to check whether the given number is odd or (5) CO2 App
even.
8 (a) i)Illustrate With an Algorithm, Pseudo code and Flowchart
for swapping of two numbers with an example program. (7) CO1 APP
(ii)Explain datatypes and its types with bytes occupied
(or) (7) CO1 App
(b) A mobile service provider offers different recharge plans with
various benefits:
1. Plan ₹199 – 28 days validity, 1.5GB/day data, 100 SMS/day
2. Plan ₹299 – 56 days validity, 2GB/day data, 100 SMS/day
3. Plan ₹399 – 84 days validity, 2.5GB/day data, unlimited
calls
4. Plan ₹599 – 365 days validity, 3GB/day data, unlimited (14) CO1 App
calls, 200 SMS/day
Write a C program using a switch-case statement where the user
selects a recharge plan and the program displays the plan details.
**********************
(Note: Und-Understand Rem-Remember Ana-Analyze App-Apply)