Riphah Community College Gujrat (Riphah International University) Program Name (Associate Degree Computer Science) Riphah community College (Gujrat) Exam Final Term (Spring-19) Semester 2nd Program Name Associate Degree of Computer Science Course Name Programming Fundamentals Course Code UR-2323 Credit Hour3 3 Credit Hours Course Instructor Ali Raza Total Marks 40 Time Allowed 2 hours Student Name: Student I.D. 1 Objective Time Allowed: 30 Minutes Total Marks: 15 Choose the most appropriate option. Overwriting and cutting is not allowed. 1. 2. 3. 4. 5. 6. 2 Header file name is written in a. Curly brackets b. Angle brackets c. Paranthesis Header file extension is a. .h b. .n c. .p Function declaration consist of a. Function name b. Return type c. Numbers and types of parameters d. All The declaration int sum(int x,int y) is called a. Function call b. Function prototype c. Function type Recursion is a. A function b. A programming technique c. Nothing C language uses which preprocessor a. Compiler b. Interpreter c. 7. 8. 9. Assembler The output of compiler is called a. Source code b. Object code c. Link code Variable that holds a large roup of similar type of data is called: a. Constant b. Multiple variable c. Array An array with no element is a. Illegal in C-language b. Legal in C-Language c. None 10. Array[4]=4.5; The value 4 indicates a. Size of array b. Array element c. Variable d. subscript 11. which of the following is not a simple data type a. int b. float c. array 12. An array can easily be stepped through by using a: a. Referential variable b. Loop c. Null Value 13. Before a structure can be used,it must be a. 3 Declared b. initialized c. None 14. The name of the structure is referred to as its a. parameter b. data type c. Argument 15. A pointer variable is designed to store a. Floating-point b. Memory address c. Both a & b 16. Each byte in the computer’s memory is assigned a unique a. Pointer b. Address c. Name 17. The statement int *a; has the same meaning as 4 a. int a; b. int* a; c. None Subjective Time Allowed: 60 Minutes Give short Answers of the following Questions. Total Marks: 25 10 Q 1: Define interpreter? (2) Q 2: Define two-dimensional array. Also write the syntax of declaring two-dimensional array (2) Q 3: What is nested structure? (2) Q 4: What is register variable? (2) Q 5: Define error handling in C-language? (2) Describe the following Questions. 15 Q 1: What is difference between local and global variables? (5) Q 2: Define how pointer and arrays work together? (5) Q 3: Write a program that inputs five integer values in an array from the user and displays the values in actual and reverse order. 5 (5)