munotes®

BSc CS Sem 2 BSc CS Semester 2 (2018 2019) Apr 2019 PROGRAMMING WITH C Question Paper - Mumbai University | munotes

BSc CS Semester 2 (2018 2019) Question Paper, Apr (64960).pdf
SEM 2 · BSc CS Semester 2 (2018-2019) · 1 May 2025

Loading PDF...

Questions asked in this paper

  • 2) Figures to the right indicate marks
  1. Q3 Illustrations, in-depth answers and diagrams will be appreciated
  2. Q4 Mixing of sub-questions is not allowed
  3. Q1 Attempt All (Each of 5Marks) (45M)
    • (A) Multiple Choice Questions
    • i. What will be the output of the following C code? printf("In while loop ");
    • a) In while loop After loop
    • c) After loop
    • d) Infinite loop
    • ii. What will be the output of the following C code? switch (printf("Do"))
    • a) Do What is the output of the following C code? Paper Subject Code: 77301 Programming with C
    • d) Depends on compiler
    • iv. Which of following logical operation can be applied to pointers?
    • d) None of the mentioned
    • v. What is the output of the following code?
    • i. The library function is used to concatenate one string to the end of another string
    • ii. AC program is basically a collection of In the C programming language, array elements always have
    • iv. An operation with only one operand is called operation
    • v. The default return type of a function in C is
    • (C) Give short answers for the following:
    • i. What is a structure? Give an example
    • ii. What is a pointer?
    • iii. Write the syntax of fopen?
    • iv. What is an escape sequence?
    • v. Give syntax of do.whileQ loop
  4. Q2 Attempt the following (Any THREE) (Each of 5Marks) (15M)
    • (a) Differentiate between compilers and interpreters
    • (b) What are the various data types available in C? Explain the memory size and range of data possible
    • (c) bitwise operators? Explain citing an example for each
    • (d) — program to accept number and find out whether it is even or odd Paper Subject Code: 77301 Programming with C
    • (e) Distinguish between If-else Structure and Switch Statement. Give example to support your answer
    • (f) Trace the output of the following code:
    • i. void main( ) default : printf(“In default”); case 1: printf(“In 1”); case 2: printf(“In 2”);
  5. Q3 Attempt the following (Any THREE) (Each of 5Marks) (15M)
    • (a) syntax and explain the use of the following functions:
    • (b) between pass by value and pass by reference. Support your answer with an example
    • (c) Howare strings in Cimplemented? Explain with an example
    • (d) What is an array? What are the advantages and disadvantages of an array?
    • (e) Write a program to copy one string to another without using standard
    • (f) Trace the output of the following code Paper Subject Code: 77301 Programming with C
  6. Q4 Attempt the following (Any THREE) (Each of 5Marks) 15 marks
    • (a) nested structures? Explain with an example
    • (b) the types of files available in C? Explain the various file opening
    • (c) on unions in C. Support your answer with an example
    • (d) malloc() and callocQ) with syntax and example. How are they
    • (e) Write to accept Student information (Roll no., name, percentage of marks) for ‘n’ students (Dynamically allocated). Store this in file and display it in well format (Accept ‘n’ from the user.)
    • (f) Trace the output of the following code:
    • i. # include <stdio.h>
  7. Q5 Attempt the following (Any THREE) (Each of 5Marks) 15 marks
    • (a) Give the difference between while() and do.whileQ loops. Use an example to support your answer
    • (b) Explain any 2 library functions provided in ‘C’ language to manipulate
    • (c) Write a program using recursive function to find factorial of a number accepted from the user
    • (d) to accept a string and check if the string is palindrome or not. Print a suitable message
    • (e) — Explain the following with declaration syntax and example
    • i. pointer to array
    • ii. array of pointers

Read from the scan above, so a character or two may differ. The scan is the original.

Report or request

Something wrong on this page? Report it and we will check it against the scan.

Quick Help

No. The full paper opens straight away, with no login and nothing to pay.

Something wrong with this paper? Report it.

Connected Papers
BSc CS / Sem 2 · 47 papers
Browse all →
Questions? Email contact@munotes.in
Done!
Done!