0% found this document useful (0 votes)
4 views

IP

Ok. Done

Uploaded by

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

IP

Ok. Done

Uploaded by

ajayvempuluru123
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF or read online on Scribd
You are on page 1/ 10
NELLORE @..@< WY NARAYANA ENGINEERING COLLEGE: COT Freshmen Engineering Department ma ‘Academic Yea Course Code: 23ES1001 lass 7 1 B.TECH course Title : Introduction to Programming Branch : Common to All MODEL QUESTIONS MODULE-1 troduction to Programming and Problem Solving S.NO Questions: CO] BL [Marks 7 [What are the characteristics of a computer? 1] 2] 2 7 _| Define Software and hardware? Lesa 2 3 Pilferentiaie between ‘Compiler and Interpreter. 1} 2 2 | Piferentate RAM and ROM aul eee [eas 7} [Wats an Kdenifier? Write any two rules oFnaming Cidentifiers. |, | > | 2 | Differentiate formatted and unformatted V/0. rl2/2 7 aplsingetchar() and putehar{) functions bane fo g_ pxplain ternary operator in C. cha a - *c)/ 10; b= 10; c= 15;d=5. 9 Praluatiee= a * 6) malereleea 10 Differentiate top down and bottom-up approaches. 1 2 2 ine basic Organization of a What is 2 Computer? Explain fiagram. at ding ‘pes OF programming computer with ne _ : 1? Explain What is a program 2 flanguages. : - in characteristics of 3 | ® What is an algorithm? Explait an 2 5 algorithm. : +) Write an algorithm to exchange the values of two variables 5 using third variable. - 7 | What is a flow chart? Explain various symbols used id 7 5 flow char. ; b) Design a flow chart to find whether a given number i 3 even or odd. 5 _| Explain the compilation and execution process. 5 i ¢ | Explain the basic structure ofa Cprogram witha diagram. |], |=) What is a data type? Explain various data types in © witht 10 7_| examples. ieee g | What is@ constant? Explain different types of C ial oer constants with examples. > | ee is a Variable? Explain the rules for naming the, | > 5 variables. b) Write aC program to add given two integers and display 5 the result. 19 | Explain about the basic Input and Output functions in C. i] 3] 0 Explain di : 11 | Explain different C Operators with examples. tile33 to Explai ; 12. | ® Explain about Type Conversion and Type Casting 1] 3 3 5 b) Explais Palin Tin an Space complexities of algorithms. gyre ac RAR RA ce op ~Controt Seractures Control SO CO] BL [Marks ‘SNO Questions 2 ii What are Simple sequential programs? 3 s ie of ifelse statement anlar . [Draw Flowshart to show te working pine ns: ‘wo integers. 2A, Beil 72 rite a C program to find the greatest among giver lAns: fee Kc > int main Q) int mumt, murn2; num =12,num2"13; if (ouml = num2) printf("both are equal’ else if (aural > num2) printf("%d is great", uml); else printf("%6d is greater", num2); return 0; IWrite a C program to print the ASCII Value ofa given Character. ns : include int main) { char ¢; printi("Enter a character: "); seanf("%e", &e); 1/ Yd displays the integer value of a character 1/ %e displays the actual character printf("ASCII value of %c = %d", ¢, ¢); return 0; ite the synlax of ns if (oso Vy arement 1; —s le if conten 2) ee if oon What isthe se of break Keyword in Switch statement? ns: The break statement to end processing of @ particular labele in the switch statement. It branches to the end of the swite | the program continues 0 the next labele Statement Wi statement. Without break tatement, executing the statements until a break or the end of th statement is reached Then is the default Block executed in Switch statement? |Ans: The default statement is executed if no case constant-expressi falue is equal to the value of expression . If there's no default statement find no case match is found, none of the statements in the switch body get -xecuted. There can be at most one default statement. |What is anested loop in C? Ans : A nested loop means @ loop statement inside another loo} statement, That is why nested loops are also called “loop inside loops“. [There is no specific limit to how many for loops can be nested ins another for loop Write a C program to print alphabels rom AtoZ: Jans: include nt main) ( char Pi = aed controlled and exit coniratied loops inc. aay 5 ; e loop in which test condition is checked in the beginning of th poop are Known as entry controlled loop. For Example: while loop jereas when statements inside the loop body is ‘executed and then th condition is checked that loop is known to be 35 exit controlled loop. Ex do while loop. MODULE-I Control Structures S.NO CO | BL | Marks 1 Explain the following: 2 bo2 fs (i) Simple if Statement (ji) if else Statement : |Explain the following: 2 a 2 |G) Nested if Statement (i) else if Ladder Statement 2 3 3 _ | Explain switch statement in C language with an example. 71 2 no 7 Eexlain in detail about while Loop Statement with an example] 2 | 5 a fprogram. j Explain in detail about do while Loop Statement with an ages rs Lxample program. Explain in detail about Tor Loop Statement with an exampld 2 |, ; program. ?, o [Explain in detail about break and continue Statements with an | "2 10 7 _ example programs. 2 g Pela in detail about goto Sttemens with an omar {example programs. 10 =) Explain the working principle of while Toop. I 9 |4) Write a C program to find whether the given number i 2 5 palindrome or not. 3 10 Design Algorithm and Flow chart to the problem of finding | 2 whether the given number is Even or Odd. 3 5 ) Write a C Program tothe above suid problem and show the 5 expected Result. }ODULE-IIT yeand Strings ‘Ans: ‘aera < estions c SN Questi 0 oO 1 | Whatisan Array? 3 Daline and Graw the memory model ofa one-dimensional Array. | 3 2 3 | How to initialize 0 ne-dimensional array? 3 3 op | Whats Array traversal? 3 : 5 | How to declare a two-dimensional array? 3 2 Differentiate one-dimensional and two-dimensional arrays. 3 2 6 7 _| Can we declare an array without specifying the size ofan array? | 3 5 g_ | How to access the elements of an array? 2 2 9 | Why NULL characters used in String? 3 10, | Explain any two, string manipulation library functions. 3 2 MODULE-UL ‘Arrays and Strings What is a String? Explain Declaring and Initializing of | 3 10 7 | Strings with examples 2 8 Explain 2D array with matrix addition program as an] 3 2 10 example, 9 Explain Printing of Strings with examples. 3 2 10 Explain String manipulation functions I 10 3 10 MODULE-IV Pointers & User Defined data types SN ‘Questions: CT] BL | Mark ° ° s 1 | What are the advantages of pointers in C? P23 What is syntax and example for declaring a pointer variable? +P 2 ZI - - = 3 | What is syntax and example for initializing a pointer variable? a) 2 the data variable direagy a5 f T [How to access the value 0 indirectly? inter? What is the purpose of a void point i inter? 6 | What is the purpose of pointer to point 7 declaring a structure’ What is the syntax for pa variable for structure? 8.__| What is the syntax for creat - — 9. | What is the syntax for declaring a union? 10. "| What is the syntax for initializing a structure? MODULE-IV ‘| Pointers & User defined data types | SN ©] 8 ] Mar ° Of/ re | 1 [ 8) What is a pointer? Explain declaration and initialization | 4} > 3 of @ pointer in ¢ with syntax and examples, 5 b) Explain array of pointers. 3) Explain about referencing dereferencing of pointer | 4 oI 2 | variables with an examples, 3 5 b) Explain in detail about multiple indirection in C. 3° | Explain in detail about pointer arithmetic in C 43) iD ‘4 [Explain in deta sGout array manipulation using pote] 4] 3} To 3 | 8. Why do we need amcuncy ee d in C language? win a Stucture? How to declare oat intalize structure with syntax and example prowen 7 agi snzes [a0 7 10 EER ae eee [Explain about Nesting of Structures wi ‘and example program, rest sy 2 to What are the differences between structure and union. z 10 Explain about the following: 7 = a) Array of structures b) Self referential structures z MODULE-V Functions & File Handling S.N Questions C | BL | Mark 0 ° s 1 | What is a Function? 5 2 2 2. | What is Function declaration? em ee 3. | What is Function call? S|) 2m 2 4_| What isa function argument? 5] 2 2 What is the use of return statement in functions? 5 2 2 5 @ | Write a function in C that accepts two integers and return the 5 2 2 ‘Sum of them. 7 | What are the types of functions based on argumentsand return — | > | 2 2 values? 8 | What are library functions? 3|.2 p2 9. | What isa File in C? How many types are C Files? 3 2 2 10. | Differentiate Text and Binary Files in C. sfo2 [2 Cy] B | Mar | oft ims | Tay What so Function? What are advantages of using |~5 | ~2 3] i functions in C? | | |b) Explain Function declaration with examples. | ; 5 | } | Explain Function definition with ‘examples. 5 110 } > Bal t= - ary | [3] Explain () Function Declaration (ii) Function Call oT 3 Saal | Ios | [¥_| Develop a C program by writing a function that finds the sy) 4] ] | maximum of two numbers. | | | | [S| Explain Function return types and arguments. sys] | |__| Explain parameter passing techniques. ~Psy,s] wv] | Fas’ | [7] Explain storage classes in C. Y s.| 3 | to | | ‘ | I [S_|@) What is @ File? Explain advantages of using files. 5 pal | b) Explain the types of files in C. [eee | | | 9] Explain the Operations on Files in C. Je ies | lo | | | T6. | Explain random access to files in G. Siig | ete |

You might also like