Practice Test 1 - Cpr Jan 2008

  • November 2019
  • PDF

This document was uploaded by user and they confirmed that they have the permission to share it. If you are author or own the copyright of this book, please report to us by using this DMCA report form. Report DMCA


Overview

Download & View Practice Test 1 - Cpr Jan 2008 as PDF for free.

More details

  • Words: 172
  • Pages: 2
K. K. Wagh Polytechnic, Nashik – 3 Semester – II

Practice test – 1 Academic year – 2007-2008 Subject: Programming in C [9017]

================================================================= Name:______________________________________________ Roll No.:_________ Class:____________

Marks obtained out of 20:

Date of the Exam:-

Examiner’s sign:_____________

Note: All the questions are compulsory. Q.1

Attempt any two. (2*2) 1. Give the syntax of scanf( ) function.

4

Ans:

2. What is constant? Give any two examples. Ans:

3. Enlist different format specifiers. Ans:

Q.2

Attempt any two. (4*2) 1. Write the appropriate syntax of switch-case statement.

8

Ans:

2. Write a program to find whether the entered number is negative and even or not using nested if-else. Ans:

Ans:

Q.3

3. Write a program to accept fahrenheit temperature and print its centigrade equivalent temperature on the screen. TF = Fahrenheit Temp. TC = Centigrade Temp. TC = (TF − 32) × 5/9

Attempt any two. (4*2) 1. Explain: Relational operators.

Ans:

2. Write the rules for writing variables names. Ans:

3. Differentiate among unary, binary and ternary operators. Ans:

8

Related Documents