[go: up one dir, main page]

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

Problem-Solving Through Programming: First/Second Semester B.E. Degree Examination

The document is a model question paper for Problem Solving Through Programming subject with 5 modules and 10 questions. It provides guidelines for answering questions including choosing at least one question from each module and using C code snippets. The questions assess various C programming concepts like data types, operators, control structures, functions, arrays, strings, structures, unions, pointers, and preprocessor directives. Students need to answer 5 full questions out of the 10 questions covering all the modules.

Uploaded by

Anser Pasha
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)
164 views2 pages

Problem-Solving Through Programming: First/Second Semester B.E. Degree Examination

The document is a model question paper for Problem Solving Through Programming subject with 5 modules and 10 questions. It provides guidelines for answering questions including choosing at least one question from each module and using C code snippets. The questions assess various C programming concepts like data types, operators, control structures, functions, arrays, strings, structures, unions, pointers, and preprocessor directives. Students need to answer 5 full questions out of the 10 questions covering all the modules.

Uploaded by

Anser Pasha
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

Subject Code-21PSP23/13

Model Question Paper-I with effect from 2021 (CBCS Scheme)


USN

First/Second Semester B.E. Degree Examination


PROBLEM-SOLVING THROUGH PROGRAMMING
TIME: 03 Hours Max. Marks: 100

Note: 01. Answer any FIVE full questions, choosing at least ONE question from each MODULE.
02. Use C code snippet to illustrate a specific code design or a purpose.

Module -1 Marks
Q.01 a Describe the evolution of Computers by mentioning how computers in one 8
generation are better than their predecessors.
b Define the following with suitable example. 5
i. Bit ii. Nibble iii.Byte iv. Word v. Kilo byte
c How primary memory is different from secondary memory? Explain 7
OR
Q.02 a What are enumeration variables? How are they declared? What are the advantages of 6
using them in a program?
b Explain the various rules for forming identifier’s names. Give examples for valid and 8
invalid identifiers names for the same.
c Write a C program to calculate area of a circle. 6
Module-2
Q. 03 a How similar and different while & for loops are? Give example 8
b Write a C program to print numbers from m to n. (where n > m) 6
c Demonstrate the working of break and continue statement with a suitable example 6
OR
Q.04 a Develop a C program to plot a Pascal’s triangle 8
b Compare if..else with switch statement 7
c List various commonly used format specifiers. Explain any two of them. 5
Module-3
Q. 05 a How 2D array is represented in memory? Explain with a suitable example 8
b For a array declared as int a[50], compute the address of a[35] if a’s base address is 2
1000 and word size=2
c What are strings? Write a C program to swap two strings 10
OR
Q. 06 a Write a C program to implement Bubble sort technique (ascending order) and trace 10
the program for the following input: 58 42 10 25 60
b Mention various operations that can be performed on strings using built-in functions. 8
Explain any two functions.
c Mention the purpose of a Null Character in C strings. 2
Module-4
Q. 07 a Demonstrate the use of C user-defined functions with a suitable example 10
b What is recursion? Write a C program to computer factorial using recursion 10
OR
Q. 08 a Differentiate between call by value and call by reference using suitable examples 10
b Define a function. List various advantages of a function. 5
c How actual parameters are different from formal parameters? Explain 5
Module-5
Q. 09 a How does a structure differ from an array? 5
b Define a structure by name DoB consisting of three variable members dd, mm and yy 10
of type integer. Develop a C program that would read values to the individual
member and display the date in mm/dd/yy form.

Page 01 of 02
Subject Code-21PSP23/13
c Write the result of the following C code: 5
int num1=10, num2=20;
int *p=&num1, *q=&num2;
*p++=*q++;
printf(“%d %d”,num1,num2);
OR
Q. 10 a How structure in C is different from union? Give example 6
b What is a pointer? Discuss Pointer arithmetic with suitable C code 7
c Narrate the purpose of various C language Pre-processor Directives 7

Page 02 of 02

You might also like