0% found this document useful (0 votes)
85 views6 pages

BOP Paper 2019

This document contains the question paper for the Theory Examination held in November/December 2017 for the 1st semester Basics of Programming (CSIR-11) course at the National Institute of Technology, Kurlakshetra. The question paper contains 8 questions to be attempted in 3 hours. Students are required to answer 5 questions out of the 8, with each question carrying 10 marks. The questions cover topics related to computer systems, C programming language constructs like operators, functions, arrays, structures, strings and more. Sample programs are also asked to illustrate certain concepts.

Uploaded by

Prince G.
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)
85 views6 pages

BOP Paper 2019

This document contains the question paper for the Theory Examination held in November/December 2017 for the 1st semester Basics of Programming (CSIR-11) course at the National Institute of Technology, Kurlakshetra. The question paper contains 8 questions to be attempted in 3 hours. Students are required to answer 5 questions out of the 8, with each question carrying 10 marks. The questions cover topics related to computer systems, C programming language constructs like operators, functions, arrays, structures, strings and more. Sample programs are also asked to illustrate certain concepts.

Uploaded by

Prince G.
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/ 6

downloaded from www.nitkkrnotes.

website
search "nitkkrnotes" on google to find more.
\
.:]
l
L,:--

]ONl!r, ]1.9'l'1TU]'E Of' T"l-lNOLI-]GY' ItilkIJ]


S}I ETRN
re-4'[
THEORY EX.TMINATION
0 7 oEC 2018
Qlrcsljorl l)aP'r-

Monlh and Ycar of thc llxamiDation: NoV/DeC-2O14

B.Tech. Scmcstcr: Ist


I)rogrammc:

Subjcct: Baaics of PrograEEing

Course No: CSIR- l1 Marimum Marks: 5O

Numbcr ()f Qucslions 10 bc attcmpl'd: 5 Timc allowcd: 3 Hours

Total No. of l)agcs uscd: 2


Tolal No- of Qucstions: 8

Thecandidates,bcforestartingtowritcthcsolution,shouldpleascchcck
tt'"' ;;;;;;p* ior anv ai-"c'cp"""v-' '19 also ensure that thev have
treen delivered the question p"p"t right course T1" 11d "uq""'
"i
suitably and state, additionat data requrred'
rl any'
ilai.. ,r"""-"
Note: All Questions are ComPulsorY
1
1. Gtq: c ra"s""Eaata iype can bc classified as:
"
. Primary data tYPe
. Derived data tYPc
. Uscr-dehned data ryPe
Give thc bricf dcscription of abovc data types' ,
1b1g, Wh"t do yo, mean
by variables in C language' Describe different
type s of variables. 5
{c)Q: ljiscuss the following
operators in C l'anguage:
Arithme tic oPerator
Relational OPerators
I-ogical Opcralors
Assignment OPerators
Incremcnts and Decrement Operators
Conditional OPerators
Bitwise OPerators
. -pe.ro, "p.,o.".. ; ,:::t-:. :_ ; i;:;;;;- fn"".,r"*
(a)Q: What do you mean 'by sraremcrrL rrr L ra'r'qsE! - help of
5

different types of statements used in C language


with the
examples'.
fi;;; i" an Array. How to declare and initialize an Array? Also
5
F)O,
'-'- di".r""theadvan@
1,.T.(
;r(llll ]) 1ae( a nrl disr
(h)Q Writt lr (
l)l.ogf:]ln I jt gl\" rl
()f ltol.
(c)Q: Wr-itc a (l llrogram to find tlrc St:<xrrrd Largcst &, Srna csi
Itlcmcnl.s in an Array.
4. {a)(): A numbcr is cl'rLcrcd through thc kcyboard. Writc a prograrn in .t.s
C languagc to gct tlrc rcvcrscd numbcr. n lso chcck wllcthcr thc
original and rcvcrscd numbcr arc cqual or not?
(b)Q: Writc a C program that acccpt thc numbcrs unlil it bccomcs t.5
Trfo-
(c)Q: Writc a C program to print thc foliowing pattcrr,. 5
i
23
4 56
7 a910
654
32
1
Write a program in C language to frnd the typc of trianglE by
taking input for thc sides from tle keyboard (scalene, isoscetei,
equihteral).
(b)Q: Writc a program in C languagc to multiply two matrices of ordcr
3x3.
(a)Q: Discuss thc scftware de.relcprnent life cyc.!e.
(blQ: Differentiatc betwecn call- by -value and call by-refcrence q,ith 2
suitablc cxamplc.
(c)Q: Writc short note on following: 3
i. Compiler.

(a)Q: Write a program to compute cosine series:


Cos(x|: I - x^2 I 2l+x^4 I 41. ---x^6/6!..........x^n/n!
(b)Q:Write a C program using stnrcture to calculate a party expenses.
This program will read item name, price, quantity and calculate
amount (price*quantitlz), using this program maximum 50 items
can be read and calculate the total paid amount.
(clQ: Write C pro8ram to replace all EVEN elements by O and Odd
elements bv 1 in l-D
(a)Q: What are main characteristics of C language?
(b)Q: Write a C program to remove all characters in a String Except
Alphabets.
(c)Q: Write a C program to Find ttre Number of Voweli, C-onsonants,
Digits and White

search "nitkkrnotes" on google to find more.


7 f
0 4 oEC 2017

NATIONAI- INSTITUTE oT' TE(]I INOLOGY, KTJRT]KSHETRA

Theory flxamination: Nov/Dec 2017 Scmcster: l" Iloll No:

Subject: Basics ofProgramming (CSIR-11) Duration: 3 hours MM: 5t)

NOTE: 1 .The question paper contains eight queslions.


2. The total number ofqueslions to be ans$cred is five.
3. AII questions are of equal marks.
4. Attempt all parts of a question at one place.

Qurslion l: I5*2=10 marksl


i). Analyze the different components ofa computer system uith the help ofblock diagram. Give
the difference betueen software and hardwarc with examples-
ii). What do you understand by operating system? what are its functions? Cive name of three
operating systems.

Question 2: I5*2=10 mrrksl


i). what are the different opemtors available in C? Explain with examples.
ii). Write a program in C to read an inleger number from keyboard, add I to it if the number read
is even, again add 1 to it ifthe number is less than 20, otherwise keep the number unchanged
and give the final result.

Qucstion 3: l5*2=10 markl

i), Differentiate nested-if-construct ftom switch-case-construct with the help ofexample.


ii). Write a progam to print the following pattem:

+,t

***, *

Question 4: [5*2=10 marks]


i). write aCprogam to find the factorial ofan inputted number.
ii). Write a C program 1o find the largest number amo[g three numbers.

Question 5: 15*2:10 narksl


i). What do you understand by function, functiofl declaration and function definition?
Explain the categories offunctions in detail with an example ofeach.
ii). What is the difference between call by value and call by reference (pointer).

Question 6: [5i2=10 marks]


i). What are the advantages and disadvantages of anays? Write a function in C to find
sum and average ofthe list (array) ofelements.
Page l of 2
ii). W le a progranr in C 10 storc and Prir1l multiplication oItuo nralrix'

l5*2=r0 mrrksl
Q'restion 7:
Program to creatc
i). What is the diffe.ence between slnrcture and array? Write a
structure SySfEM, store and print a rccord of dcsktop
syslem The fields are
ufacluring '
sysle/'t id, compdny-rttone' syslem-cosl' operali'tg-systefi' lear-of 'na
a proglam to:
ii). Analyze memory representation ofstriirg with '\0' character' Write
- find length ofstring
- Reverse and check string is palindrome or not'

I2*5=10 markrl
Question 8: AtttmPt anY fiv€.
i). Compare Compiler, Assembler and Interprcter?
ii). What are the diffsrenl primary dala types avaiiable irr 'C'?
iii). Differentiate between )rritu loop and do" w'le loop?
a C program to swap values of two variabtes without
using a third variable'
ivj. Write
vi. Differentiate between pre-increment and poslincremen! operators?
vi). Give difference between ':'
and '- =' operator?
vii;. Wlrat will happen when you access the array more than its dimension?
viii). Writ€ a function in C to count number ofcharacters in a strirg'

search "nitkkrnotes" on google to find more.


Page 2 ot 2

You might also like

pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy