Name :. Roll No. :... Invigilator s Signature :.. CS/B.TECH (NEW)/SEM-2/CS-201/ BASIC COMPUTATION & PRINCIPLES OF COMPUTER PROGRAMMING

Similar documents
Name :. Roll No. :... Invigilator s Signature : INTRODUCTION TO PROGRAMMING. Time Allotted : 3 Hours Full Marks : 70

VALLIAMMAI ENGINEERING COLLEGE SRM NAGAR, KATTANGULATHUR

(i) Describe in detail about the classification of computers with their features and limitations(10)

Questions Bank. 14) State any four advantages of using flow-chart

DETAILED SYLLABUS INTRODUCTION TO C LANGUAGE

PROGRAMMING IN C AND C++:

C++ ARRAYS POINTERS POINTER ARITHMETIC. Problem Solving with Computers-I

M4.1-R3: PROGRAMMING AND PROBLEM SOLVING THROUGH C LANGUAGE

Introduction to C++ Introduction. Structure of a C++ Program. Structure of a C++ Program. C++ widely-used general-purpose programming language

Sample Examination. Family Name:... Other Names:... Signature:... Student Number:...

Introduction to C++ with content from

3.Constructors and Destructors. Develop cpp program to implement constructor and destructor.

Scheme G. Sample Test Paper-I. Course Name : Computer Engineering Group Course Code : CO/CD/CM/CW/IF Semester : Second Subject Tile : Programming in C

M3-R4: PROGRAMMING AND PROBLEM SOLVING THROUGH C LANGUAGE

Aryan College. Fundamental of C Programming. Unit I: Q1. What will be the value of the following expression? (2017) A + 9

Introduction to C Language (M3-R )

UNIT I : OVERVIEW OF COMPUTERS AND C-PROGRAMMING

Roll No. :... Invigilator's Signature :.. CS/B.TECH(CSE/IT)/SEM-5/CS-501/ OPERATING SYSTEM. Time Allotted : 3 Hours Full Marks : 70

Multiple Choice Questions ( 1 mark)

FORM 2 (Please put your name and form # on the scantron!!!!)

Question Bank (SPA SEM II)

Algorithms & Data Structures

Computer Programming C++ (wg) CCOs

M1-R4: Programing and Problem Solving using C (JULY 2018)

ESC101N: Fundamentals of Computing End-sem st semester

Groups of two-state devices are used to represent data in a computer. In general, we say the states are either: high/low, on/off, 1/0,...

FORM 2 (Please put your name and form # on the scantron!!!!) CS 161 Exam II:

Part I Basic Concepts 1

COMPUTER APPLICATION

PES INSTITUTE OF TECHNOLOGY (BSC) I MCA, First IA Test, November 2015 Programming Using C (13MCA11) Solution Set Faculty: Jeny Jijo

I BCA[ ] SEMESTER I CORE: C PROGRAMMING - 106A Multiple Choice Questions.

FORM 1 (Please put your name and form # on the scantron!!!!) CS 161 Exam II: True (A)/False(B) (2 pts each):

CS201- Introduction to Programming Latest Solved Mcqs from Midterm Papers May 07,2011. MIDTERM EXAMINATION Spring 2010

PERIYAR CENTENARY POLYTECHNIC COLLEGE Periyar Nagar- Vallam Thanjavur

Pace University. Fundamental Concepts of CS121 1

Chapter 10. Programming in C

DEPARTMENT OF ELECTRICAL AND ELECTRONIC ENGINEERING PROGRAMMING TECHNIQUES I EE271

Contents. Preface. Introduction. Introduction to C Programming

C Programming Language. Microcomputer Architecture and Interfacing Colorado School of Mines Professor William Hoff

Department of Computer Science & Engineering Indian Institute of Technology Kharagpur. Practice Sheet #04

CS201- Introduction to Programming Current Quizzes

PESIT-BSC Department of Science & Humanities

A3-R3: PROGRAMMING AND PROBLEM SOLVING THROUGH 'C' LANGUAGE

CS1800 Discrete Structures Final Version A

C Programming. Course Outline. C Programming. Code: MBD101. Duration: 10 Hours. Prerequisites:

INDIAN INSTITUTE OF TECHNOLOGY KHARAGPUR Stamp / Signature of the Invigilator

Midterm Exam 2 Solutions, C programming

a) Write the signed (two s complement) binary number in decimal: b) Write the unsigned binary number in hexadecimal:

ECE 2030B 1:00pm Computer Engineering Spring problems, 5 pages Exam Two 10 March 2010

Sardar Patel University S Y BSc. Computer Science CS-201 Introduction to Programming Language Effective from July-2002

Functions. Lab 4. Introduction: A function : is a collection of statements that are grouped together to perform an operation.

INTERNATIONAL INDIAN SCHOOL, RIYADH XI XII BOYS SECTION

Reg. No. : Question Paper Code : B.E./B.Tech. DEGREE EXAMINATION, JANUARY First Semester GE 6151 COMPUTER PROGRAMMING

Time: 8:30-10:00 pm (Arrive at 8:15 pm) Location What to bring:

CS 33. Data Representation, Part 1. CS33 Intro to Computer Systems VII 1 Copyright 2017 Thomas W. Doeppner. All rights reserved.

A6-R3: DATA STRUCTURE THROUGH C LANGUAGE

Subject: Fundamental of Computer Programming 2068

Introduction to Computer Science Midterm 3 Fall, Points

CS & IT Conversions. Magnitude 10,000 1,

Computer Systems Programming. Practice Midterm. Name:

CE161-4-AU UNIVERSITY OF ESSEX. Undergraduate Examinations 2014 DIGITAL SYSTEMS ARCHITECTURE. Time allowed: TWO hours

INTERNATIONAL INDIAN SCHOOL, RIYADH XI XII BOYS SECTION. Subject- Informatics Practices

Dept. of CSE, IIT KGP

Roll No. :... Invigilator's Signature : GRAPHICS AND MULTIMEDIA. Time Allotted : 3 Hours Full Marks : 70

COMPUTER SCIENCE SECTION A

CONTENTS. PART 1 Structured Programming 1. 1 Getting started 3. 2 Basic programming elements 17

Type Checking. Prof. James L. Frankel Harvard University

IECD Institute for Entrepreneurship and Career Development Bharathidasan University, Tiruchirappalli 23.

ECE 250 / CS 250 Computer Architecture. C to Binary: Memory & Data Representations. Benjamin Lee

CSCE 110 Dr. Amr Goneid Exercise Sheet (7): Exercises on Recursion

CS/B.TECH/CSE(New)/SEM-5/CS-504D/ OBJECT ORIENTED PROGRAMMING. Time Allotted : 3 Hours Full Marks : 70 GROUP A. (Multiple Choice Type Question)

Computer Programming. C Array is a collection of data belongings to the same data type. data_type array_name[array_size];

Reg. No. : Question Paper Code : 27157

Page. No. 1/15 CS201 Introduction to Programmming Solved Subjective Questions From spring 2010 Final Term Papers By vuzs Team

Contents. A Review of C language. Visual C Visual C++ 6.0

COMPUTER SCIENCE (083)

FORM 1 (Please put your name and section number (001/10am or 002/2pm) on the scantron!!!!) CS 161 Exam II: True (A)/False(B) (2 pts each):

Roll No. : Invigilator's Signature :.. GRAPHICS AND MULTIMEDIA. Time Allotted : 3 Hours Full Marks : 70

Programming for Problem Solving 105A L T P Credit Major Minor Total Time

Lexical Considerations

Review of the C Programming Language for Principles of Operating Systems

CS356: Discussion #6 Assembly Procedures and Arrays. Marco Paolieri

Lecture 8: Pointer Arithmetic (review) Endianness Functions and pointers

[CHAPTER] 1 INTRODUCTION 1

Code No: R Set No. 1

Goals for this Week. CSC 2400: Computer Systems. Bits, Bytes and Data Types. Binary number system. Finite representations of binary integers

ECE 2020B Fundamentals of Digital Design Spring problems, 6 pages Exam Two 26 February 2014

CHAPTER 1 Introduction to Computers and Programming CHAPTER 2 Introduction to C++ ( Hexadecimal 0xF4 and Octal literals 031) cout Object

COS 126 Midterm 1 Written Exam, Fall 2009

Lecture 4: Outline. Arrays. I. Pointers II. III. Pointer arithmetic IV. Strings

UNIT 2 ARRAYS 2.0 INTRODUCTION. Structure. Page Nos.

Come and join us at WebLyceum

AHLCON PUBLIC SCHOOL, MAYUR VIHAR I, DELHI ASSIGNMENT CLASS XI Session Chapter 1: Computer Overview

ENGINEERING PROBLEM SOLVING WITH C++

ECE264 Fall 2013 Exam 1, September 24, 2013

Introduction to Programming Using Java (98-388)

(Following Paper ID and Roll No. to be filled by the student in the Answer Book)

SOME ASSEMBLY REQUIRED

LESSON 5 FUNDAMENTAL DATA TYPES. char short int long unsigned char unsigned short unsigned unsigned long

An array is a collection of data that holds fixed number of values of same type. It is also known as a set. An array is a data type.

Transcription:

Name :. Roll No. :..... Invigilator s Signature :.. CS/B.TECH (NEW)/SEM-2/CS-201/2012 2012 BASIC COMPUTATION & PRINCIPLES OF COMPUTER PROGRAMMING Time Allotted : 3 Hours Full Marks : 70 The figures in the margin indicate full marks Candidates are required to give their answer in their own words as far as practicable. GROUP A ( Multiple Choice Type Questions ) 1. Choose the correct alternatives for the following: i) Operating system is ii) iii) a) Appl cation software b) System software c) Both ( ) and (b) d) None of these. ALU is a part of a) memory b) CPU c) output device d) input device. Pointer is a) a variable containing the address of a variable b) a value c) a memory location d) none of these. 10 1 = 10 2173 [ Turn over

iv) Which will be the output? void main () { int x = 7, y = 5; x = y++ + x++; y=++y + ++x; printf("%d%d", x, y); } a) 12 14 b) 12 20 c) 97 d) 12 19. v) A function may contain a) one return statement b) two return statemen s c) more than two return st tements d) none of these. vi) Which one of the ollowing is a Bitwise operator? a) < b) >= c) && d) <<. vii) The output of int act=1; for (i=0;i<fact;i++); { fact=fact*i; printf("%d", fact); } is a) 24 b) 5 c) infinite loop d) none of these. 2173 2

viii) Which one of the following declaration is invalid? a) int 2A b) int A2A c) int A2 d) int AA2. ix) Which one is the correct output? char a[]="computer"; printf("%d",strlen(a)); a) 9 b) 10 c) 8 d) 11 x) In hexadecimal system D is equi alent to the number in decimal is a) 10 b) 12 c) 13 d) 15. GROUP B ( Short Answer Type Questions ) Answer any three of the following. 3 5 = 15 2. Describe the functions of various units of a digital computer using a neat block diagram. 3. Write a complete C program to generate Fibonacci series. 4. a) Convert (45 5675) into hexadecimal. b) What are 2's complement numbers? What is signed magnitude number representation? What is its disadvantage? 2 + 3 2173 3 [ Turn over

5. Write a C program to check if a string taken as input is a palindrome or not without using string related functions supported by the compiler. 6. Write C program to print the following : 1 1 2 2 3 4 3 4 5 6 4 5 6 7 8 GROUP C ( Long Answer Type Questions ) Answer any three of the following. 3 15 = 45 7. a) Write a comparative study between for, while and do-while loop. b) Write a c mplete C program to print the following pattern for n number of rows, where n is supplied extenally. * * * * * * * * * * * * * * * * * * * * * * * * * * * * * c) What is the difference between break and continue statement? Explain with example. 5 + 5 + 5 2173 4

8. a) What is subscripted variable? b) Explain "C doesn't support Bound Checking". c) Write a complete C program to convert a decimal number consisting of arbitrary number of digits into its binary form using 1-D array. d) Write a complete C program to find out the Trace of a square matrix [Trace means the sum of Principal Diagonal Elements]. 2 + 3 + 5 + 5 9. a) What is recursion? b) What is the d fference between recursion and iteration? c) Write a f nction (Recursive/Non-Recursive) power (a, b) that can calculate b a for any floating a and positive integer b. Invoke this function into main ( ) function to calculate n x. d) Write a C function to find the length of a string and call the function from the main ( ) function. Do not use 'strlen' function in your program. 2 + 3 + 5 + 5 2173 5 [ Turn over

10. a) Explain with suitable example, the difference between structure and union in a C program. b) Suppose you have to create and maintain a Record Book of your company. Record Book consists of the following fields : (a) Employee's Name (b) Id Number (c) Salary Amount (d) Designation. How do you create and maintain this Record Book for 150 Employees of your organization if your management asks to see the salary of any particular employee? c) Explain Call-by-Value and Call-by-Address with examples. 3 + 6 + 6 11. a) Write a C program that will receive a file name and a line of text as command line arguments and write the text t that file. b) Convert the following : ( 3FA to Octal ) 16 ( 742) 8 to Binary ( 10110 0101) 2 to Decimal c) Represent the following expression using Logic Gates : S = (AX + BY) + (CD+EF) 7 + 2 + 2 + 2 + 2 2173 6

12. Write short notes on any three of the following : 3 5 a) Dynamic allocation of the memory b) Bitwise Operator c) Pointer Arithmetic d) Functions of Memory Unit of a Digital Computer e) Array of Structure f) Pointer to function and Function returning a Pointer. 2173 7