W h a t are the main steps involved in executing a p r o g r a m f r o m s o u r c e code to 2 running application?
Other Or UnclassifiedSource quality review required
Anna University
| University | Anna University |
|---|---|
| Degree | B.E. Computer Science and Engineering |
| Department | Computer Science and Engineering |
| Regulation | Regulation 2018 |
| Semester | 1 |
| Subject Code | CS6101 |
| Subject Name | Programming with C |
| Exam Session | November / December 2024 |
| Duration | 180 minutes |
| Maximum Marks | 100 |
Access the previous year question paper for your examination preparation.
View / Download PDFBrowse other previous year question papers for this subject.
View All Subject Question PapersAutomatically extracted historical question data. Academic accuracy and examination rules require verification.
| Part | Required answers | Marks per answer | Section total |
|---|---|---|---|
| A | 10 | 2 | 20 |
| B | 8 | 8 | 64 |
| C | 2 | 8 | 16 |
Proportional to section marks. This estimate uses the full exam duration without a separate reading or revision reserve.
W h a t are the main steps involved in executing a p r o g r a m f r o m s o u r c e code to 2 running application?
Other Or UnclassifiedSource quality review required
State any four special features of C L a n g u a g e 2
Short DescriptionSource quality review required
W h a t is the p u r p o s e of the conditional operator (?:) in p r o g r a m m i n g ? 2
Other Or UnclassifiedSource quality review required
W h a t is the role of header files in C language 2
Other Or UnclassifiedSource quality review required
Predict the output of the following C C o d e 2 # i n c l u d e <stdio.h> int main() { int arr[] = {10, 20, 30, 40, 50}; int *ptr = arr; printf("%d % d % d \ n " , *ptr, *(ptr + 2), *(arr + 4)); return 0; }
Other Or UnclassifiedSource quality review required
H o w does a do-while loop differ f r o m a while loop? 2
Other Or UnclassifiedSource quality review required
Write a code snippet to to declare a 2x3 niulti-dimensional array a n d initialize it 2 with values..
Other Or UnclassifiedSource quality review required
State how a pointer variable differ from a variable? 2
Short DescriptionSource quality review required
Write a function in C to calculate the factorial of a n u m b e r using recursion. 2
Other Or UnclassifiedSource quality review required
W h a t is e n u m e r a t e d d a t a t y p e ? 2
Other Or UnclassifiedSource quality review required
(i) W h a t is m e a n t by p r e c e d e n c e and associativity of operators in C ? Explain 4. with an e x a m p l e . Exemplify the use of 'break' and 'continue' statements in C with suitable 4 e x a m p l e .
Other Or UnclassifiedSource quality review required
(i) Explain h o w logical relationship is checked in C p r o g r a m ? 4 (ii) W h a t are formatted input a n d output statements in C ? Give suitable 4 e x a m p l e s .
Other Or UnclassifiedSource quality review required
(i) H o w d o y o u store and access elements in a multi-dimensional array? 4 Provide an example. f (ii) Write a C p r o g r a m to print the following on the screen using nested loops 4 1 2 3 4 5 6 7 8 9 10
Other Or UnclassifiedSource quality review required
(i) Write a C p r o g r a m to print the s u m of the following series up to n t e r m s w h e r e 4 n is given by the user: x - x^/Sl + x^/SI -... (The value of x is given by the user.) (ii) Write a C p r o g r a m to find a n d print the factorial of the first 'n' n u m b e r s that 4 are not divisible by 2 or 3.
Other Or UnclassifiedSource quality review required
Write a C p r o g r a m to sort the given list of e l e m e n t s and to find the s e c o n d 8 largest e l e m e n t in an array.
Other Or UnclassifiedSource quality review required
Explain in detail h o w the data is p a s s e d fto a function by writing a function that 8 takes a d e c i m a l n u m b e r a n d b a s e as a r g u m e n t a n d returns the equivalent n u m b e r of the given base.
ExplanationSource quality review required
(i) .Explain the use of string operators in C with e x a m p l e s 4 (ii) Write a p r o g r a m that uses a function to add a string to the e n d of another string 4 without using any library function
Other Or UnclassifiedSource quality review required
Explain in detail about the pointers in C and Write a program to swap two numbers 8' using pointers.
ExplanationSource quality review required
Write a C p r o g r a m to find the m a x i m u m and m i n i m u m elements in a sorted 8 array by passing the array pointer to a subroutine.
Other Or UnclassifiedSource quality review required
Explain the use of various pre-processor directives with suitable e x a m p l e s . 8
ExplanationSource quality review required
Brief about h o w the files are handled in C p r o g r a m s with appropriate formats 8
Other Or UnclassifiedSource quality review required
Discuss in details about the dynamic memory allocation functions in C with example. 8 I
ExplanationSource quality review required
Write a C p r o g r a m using structures to store the data of 'n' books, w h e r e 'n' is given 8 by the user (use d y n a m i c m e m o r y allocation). Include a m e n u that will allow the user to select any of the following features: a. Use a function to display the book information while getting the book with the m a x i m u m and m i n i m u m price. b. U s e a function to display the book records in alphabetical order by title. c. U s e a function to display the book records by their genre (e.g.. Fiction, Non-fiction, Science, etc.). 24 ' Discuss h o w binary files are created and m a n a g e d in C with a p r o g r a m to implement 8 the following: a. Create t w o files namely source and destination. b. R e a d a character f r o m the source file and write the s a m e into the destination file till end-of-file is not reached. c. Delete the s o u r c e file at last. 3
Other Or UnclassifiedSource quality review required
Historical analysis based on extracted question papers. Topic classifications, marks and planning estimates are provisional.