9.12TUTORIALQUESTIONS - MLR Institute of Web viewDepartment of CSE. Department of CSE. MLR Institute...

177
Department of CSE MLR Institute of Technology, Dundigal, Hyd-500043 Page 1

Transcript of 9.12TUTORIALQUESTIONS - MLR Institute of Web viewDepartment of CSE. Department of CSE. MLR Institute...

Page 1: 9.12TUTORIALQUESTIONS - MLR Institute of Web viewDepartment of CSE. Department of CSE. MLR Institute of Technology, Dundigal, Hyd-500043Page 2. MLR Institute of Technology, Dundigal,

Department of CSE

MLR Institute of Technology, Dundigal, Hyd-500043 Page 1

Page 2: 9.12TUTORIALQUESTIONS - MLR Institute of Web viewDepartment of CSE. Department of CSE. MLR Institute of Technology, Dundigal, Hyd-500043Page 2. MLR Institute of Technology, Dundigal,

Department of CSE

8. II YEAR CSE COURSE STRUCTURE (R15 AUTONOMOUS)

CODE SUBJECT L T P C

A10506 Computer Architecture and Organization 3 1 - 3

A10507 Digital Logic Design 3 1 - 3

A10470 Electronic Devices 3 1 - 3

A10562 Discrete Mathematical Structures 3 1 - 3

A10508 Object Oriented Programming using C++ 3 1 - 3

A10509 Computer Organization Lab - - 3 2

A10471 Electronic Devices and Digital Circuits Lab 1 - 3 3

A10510 Object Oriented Programming using C++ Lab - - 3 2

Total 16 05 09 22

Note: All End Examinations (Theory and Practical) are of three hours duration.T – Tutorial L-Theory P- Practical C – Credits

MLR Institute of Technology, Dundigal, Hyd-500043 Page 2

Page 3: 9.12TUTORIALQUESTIONS - MLR Institute of Web viewDepartment of CSE. Department of CSE. MLR Institute of Technology, Dundigal, Hyd-500043Page 2. MLR Institute of Technology, Dundigal,

Department of CSE

9. COMPUTER ARCHITECTURE AND ORGANIZATION (A10506)

9.0 COURSE DESCRIPTION

Course Title Computer Architecture and OrganizationCourse Code A10506Regulation MLR-15

Course StructureLectures Tutorials Practical Credits

5 1 3 3Course Coordinator Mr.P.Ram Mohan RaoTeam of Instructors Mr.P.Ram Mohan Rao Mr.Venkat siva rao Mr.D.Raghu Ms.B.Lakshmi

9.1 COURSE OVERVIEW: This course introduces the principles of computer organization and the basic architecture

concepts. The course emphasizes performance and cost analysis, instruction set design, pipelining, memory technology, memory hierarchy, virtual memory management, and I/O systems.

9.2 PREREQUISITES:

Level Credits Periods/Weeks PrerequisitesUG 3 5 Minimum awareness of Computer

9.3 A) MARKS DISTRIBUTION:

Session Marks University EndExam Marks Total Marks

Mid Semester TestThere shall be two midterm examinations.Each midterm examination consists of subjective type and objective type tests.The subjective test is for 10 marks of 60 minutes duration.Subjective test of shall contain 4 questions; the student has to answer2 questions, each carrying 5 marks.The objective type test is for 10 marks of 20 minutes duration. It consists of 10 Multiple choice and 10 objective type questions, the student has to answer all the questions and each carries half mark.First midterm examination shall be conducted for the first two and half units of syllabus and second midterm examination shall be conducted for the remaining portion.AssignmentFive marks are earmarked for assignments.There shall be two assignments in every theory course. Marks shall be awarded considering the average of two assignments in each course.

75 100

9.4 EVALUATION SCHEME:

MLR Institute of Technology, Dundigal, Hyd-500043 Page 3

Page 4: 9.12TUTORIALQUESTIONS - MLR Institute of Web viewDepartment of CSE. Department of CSE. MLR Institute of Technology, Dundigal, Hyd-500043Page 2. MLR Institute of Technology, Dundigal,

Department of CSE

S. No Component Duration Marks1 I Mid Examination 80minutes 202 I Assignment 53 II Mid Examination 80minutes 204 II Assignment 55 External Examination 3 hours 75

9.5 COURSE OBJECTIVES & OUTCOMES

Course Objectives Course Outcomes Blooms LevelI. To impart basic concepts of computer architecture and organization. To explain key skills of constructing cost-effective computer systems.

A. Students will be able to Identify various components of computer and their interconnection

BL 1 & 2

II. To familiarize the basic CPU organization and facilitate students in design of control unit

B. Students will be able to Understand the design issues of control unit and select the suitable design.Apply micro programming for control memory design

BL 1, 2, & 3

III. To facilitate students in understanding various memory devices, their interconnection and performance

C. Students will be able to understand memory hierarchy, apply cache memory mapping techniques, apply concept of virtual memory and analyze performances of cache and virtual memory

BL 1, 2, 3 & 4

IV. To facilitate students in understanding various computer arithmetic algorithms

D. Students will be able to implement multiplication and division algorithms, analyze various algorithms in terms of their execution times.

BL 1, 2, 3 & 4

V. To impart the concepts of IO interface and various IO techniques

E. Students will be able to analyze various IO mechanisms and select suitable IO mapping technique based on the given specification

BL 4 & 5

VI. To impart the key skill of pipelining and parallel processing

F. Students will be able to critique the performance variation after application of pipelining concepts and parallel processing concepts and can also design program to implement pipelining

BL 5 & 6

BLOOMS LEVEL (BL)BL 1: Remember / knowledge BL2: Understanding BL3: ApplyBL 4: Analyze BL 5: Evaluate BL 6: Create

9.6 HOW PROGRAM OUTCOMES ARE ASSESSED:

Program Outcomes Level Proficiency assessed by Blooms Level

A

An ability to apply the knowledge of mathematics, Computing, Science and engineering to solve Computer Science and Engineering problems.(Fundamental engineering analysis skills).

HSolving Gate and Text book Problems

Apply

BAn ability to design and conduct engineering experiments, as well as to analyze and interpret data. (information retrieval skills).

SSolving Gate and Text book Problems

Apply

MLR Institute of Technology, Dundigal, Hyd-500043 Page 4

Page 5: 9.12TUTORIALQUESTIONS - MLR Institute of Web viewDepartment of CSE. Department of CSE. MLR Institute of Technology, Dundigal, Hyd-500043Page 2. MLR Institute of Technology, Dundigal,

Department of CSE

CAn ability to design and construct a hardware and software system, component, or process to meet desired needs, within realistic constraints. (Creative skills).

H Assignment andGate questions

Apply andAnalyze

DGraduates will demonstrate an ability to visualize and work on laboratory and Multi-disciplinary tasks individually or as a member within the teams. (team work)

S Mini and Micro Projects Apply

E

An ability to demonstrate skills to use the techniques, modern engineering Tools, Software and equipments necessary to analyze computer engineering Problems.(Engg. Problem solving Skills)

SMicro Project Models/ Gate questions

Apply

F An understanding of professional, social and ethical responsibility N ------- --------

G

An ability to recognize the global issues like green initiatives and alternate energy sources and to take technology to villages and to recognize the rural requirements. (Engg. Application Skills)

SMicro Projects models / Gate questions

Analyze and Justify

HThe broad education necessary to understand the impact of engineering solutions in a global, economic, environmental, and societal context.

H Assignment andGate questions Analyze

I

Graduate will develop confidence for self education and acquire new knowledge in the computing discipline and ability and practice for Multidisciplinary tasks as a member within the teams

S Class Test & Seminars Analyze

J To communicate effectively S Seminars Understand & Analyze

K An ability to use the techniques, skills and modern engineering tools necessary for Engineering practice. S

Class Tests & Group Activity inclass room

Apply

LGraduates are able to participate and succeed in competitive examination like GRE, GATE, TOEFL, GMAT etc.(Continuing Education )

H GATE Apply

M

The use of current application software and the design and use of operating systems and the analysis, design, testing and documentation of computer programs for the use in Computer Science and engineering technologies.

SText Book Problems as part of Assignment

Apply

N An ability to setup an enterprise.(Employment Skills) S Placement Design and Develop

N = None S = Supportive H = Highly Related

9.7 SYLLABUS:

UNIT - ISTRUCTURE OF COMPUTERS: Computer types, Functional units, Basic operational concepts, Von-Neumann Architecture, Bus Structures, Software, Performance, Multiprocessors and Multicomputer, Data representation, Fixed and Floating point, Error detection and correction codes.REGISTER TRANSFER AND MICRO-OPERATIONS: Register Transfer Language, Register Transfer, Bus and Memory Transfers, Arithmetic Micro-Operations, Logic Micro-Operations, Shift Micro-Operations, Arithmetic logic shift unit.UNIT - IIBASIC COMPUTER ORGANIZATION AND DESIGN: Instruction codes, Computer Registers, Computer Instructions, and Instruction cycle. Timing and Control, Memory-Reference Instructions, Input-Output and interrupt. Central processing unit: Stack organization, Instruction Formats, Addressing Modes, Data Transfer and Manipulation, Reduced Instruction Set Computer (RISC), RISC vs CISC

MLR Institute of Technology, Dundigal, Hyd-500043 Page 5

Page 6: 9.12TUTORIALQUESTIONS - MLR Institute of Web viewDepartment of CSE. Department of CSE. MLR Institute of Technology, Dundigal, Hyd-500043Page 2. MLR Institute of Technology, Dundigal,

Department of CSE

UNIT - IIIMICRO-PROGRAMMED CONTROL: Control Memory, Address Sequencing, Micro-Program example, Design of Control Unit.COMPUTER ARITHMETIC: Addition and Subtraction, Multiplication and Division algorithms, Floating-point Arithmetic Operations, Decimal arithmetic operations.UNIT - IVMEMORY SYSTEM: Memory Hierarchy, Semiconductor Memories, RAM(Random Access Memory), Read Only Memory (ROM), Types of ROM, Cache Memory, Performance considerations, Virtual memory, Paging, Secondary Storage, RAID.UNIT – VINPUT OUTPUT: I/O interface, Programmed IO, Memory Mapped IO, Interrupt Driven IO, DMA. MULTIPROCESSORS: Characteristics of multiprocessors, Interconnection structures, Inter processor Arbitration, Inter processor Communication and Synchronization, Cache Coherence.

TEXT BOOKS:1. M. Moris Mano (2006), Computer System Architecture, 3rd edition, Pearson/PHI, India.

REFERENCE BOOKS:1. Carl Hamacher, Zvonks Vranesic, SafeaZaky (2002), Computer Organization, 5th

edition, McGraw Hill, New Delhi, India.2. William Stallings (2010), Computer Organization and Architecture- designing for

performance, 8th edition, Prentice Hall, New Jersy.3. Anrew S. Tanenbaum (2006), Structured Computer Organization, 5th edition, Pearson

Education Inc, 4. John P. Hayes (1998), Computer Architecture and Organization, 3rd edition, Tata

McGraw Hill

9.8 COURSE PLAN:At the end of the course, the students are able to achieve the following Course Learning Outcomes.

Lecture No.

Course Learning Outcomes

Topics to be covered Reference BloomsLevel

1 a Introduction to Computer Architecture and Computer Organization. Types of Computers T1 /Ch1 1 & 2

2 a,bFunctional Units of a computer. Basic Operational Concepts. Von Neuman Architecture. Analyzing Performance of computer

T1 /Ch1 1, 2,3 & 4

3 aUnderstanding Bus Structures. Constructing bus using multiplexer for a given specification. Analyzing performance of a bus using 3 state buffer

T1 /Ch4 1, 2,3, 4,5 & 6

4 a, c Data Representation. Number systems.Fixed point and Floating point numbers T1 /Ch3 1,2 & 3

5 a Complements. Addition and subtraction using 2’s complement T1 /Ch3 1,2 & 3

6 a Other Codes. Gray Code,EBCIDIC,2421 codes etc. T1 /Ch3 1,2

MLR Institute of Technology, Dundigal, Hyd-500043 Page 6

Page 7: 9.12TUTORIALQUESTIONS - MLR Institute of Web viewDepartment of CSE. Department of CSE. MLR Institute of Technology, Dundigal, Hyd-500043Page 2. MLR Institute of Technology, Dundigal,

Department of CSE

7 b Error Detection Codes T1 /Ch3 1,2 & 3

8 b Error Correction Codes T1 /Ch3 1,2 & 3

9 b,c Error Correction Codes T1 /Ch3 1,2 & 3

10 a,d Register Transfer Language Notation. Bus and Memory transfers T1 /Ch4 1,2

11 a,d Micro operations and types of micro operations T1 /Ch4 1,2

12 a,d Micro Operations T1 /Ch5 1,2

13 a,d,f Computer Registers and Instruction codes T1 /Ch5 1,2

14 a,b,c Instruction code and instruction cycle T1 /Ch5 1,2

15 a,d,e Timing and Control. Memory Reference Instructions T1 /Ch5 1,2

16 a,e Input Output. Interrupt handling and types of interrrupts. Applications of interrupts. T1 /Ch5 1,2,3

17 b,d Central Processing Unit. Hypothetic computer. T1 /Ch8 1,2

18 a,d Central Processing Unit. Hypothetic computer. T1 /Ch8 1,2

19 a,f Instruction Formats T1 /Ch8 1,2

20 a,e Addressing Modes T1 /Ch8 1,2,3

21 d RISC vs CISC T1 /Ch8 1,2

22 c,d Designing Control Unit. Hardwired control Unit T1 /Ch7 1,2,3,4

23 a,d,e Control memory T1 /Ch7 1,2,3

24 a,f Address Sequencing T1 /Ch7 1,2

25 b,c Micro Programmed Control Unit T1 /Ch7 1,2,3,4,5 & 6

26 a,d,f Micro Programmed Control Unit T1 /Ch7 1,2,3,4,5 & 6

27 a,e Computer Arthmetic. Multiplicaton algorithm T1 /Ch10 1,2,3

28 a,d Booth’s Algorithm T1 /Ch10 1,2,3

29 a,d Booth’s Algorithm T1 /Ch10 1,2,3

30 a,d Division Algorithm T1 /Ch10 1,2,3

MLR Institute of Technology, Dundigal, Hyd-500043 Page 7

Page 8: 9.12TUTORIALQUESTIONS - MLR Institute of Web viewDepartment of CSE. Department of CSE. MLR Institute of Technology, Dundigal, Hyd-500043Page 2. MLR Institute of Technology, Dundigal,

Department of CSE

31 a,d Division Algorithm T1 /Ch10 1,2,3

32 a,e,f Floating point arithmetic operations T1 /Ch10 1,2,3

33 e,f Memory Hierarchy T1 /Ch12 1,2

34 d,f Semi conductor memories. RAM memory addressing T1 /Ch12 1,2,3

35 a,e,f ROM T1 /Ch12 1,2,3

36 b,c,e Cache Memory T1 /Ch12 1,2

37 a,e,f Mapping techniques T1 /Ch12 1,2,3

38 a,c,d,e,f Cache Performance considerations T1 /Ch12 1,2,3,4

39 a,d,e,f Virtual Memory T1 /Ch12 1,2,3

40 a,d,f Paging and Demand Paging T1 /Ch12 1,2,3,4,&5

41 a,d,e,f Segmentation T1 /Ch12 1,2,3,4,&5

42 a,d,e,f Secondary Storage HDD T1 /Ch12 1,2

43 a,d,f Secondary Storage HDD T1 /Ch12 1,2

44 a,d RAID T1 /Ch12 1,2,3

45 a,d RAID levels T1 /Ch12 1,2,3 & 4

46 a,d,e,f Introduction to IO Interface T1 /Ch11 1,2

47 a,e I/O vs Memory Bus T1 /Ch11 1,2

48 a,b Isolate I/O, Memory Mapped I/O T1 /Ch11 1,2

49 b,c Interrupt Driven I/O T1 /Ch11 1,2

50 d,e Direct Memory Access T1 /Ch11 1,2

51 a,d,f Characteristics of Multiprocessors and inter connection structures T1 /Ch11 1,2

52 a,d Inter processor arbitration T1 /Ch11 1,2

53 a,d Inter processor arbitration T1 /Ch11 1,2

54 a,d,f Inter Processor Communication and Synchronization T1 /Ch11 1,2,3

MLR Institute of Technology, Dundigal, Hyd-500043 Page 8

Page 9: 9.12TUTORIALQUESTIONS - MLR Institute of Web viewDepartment of CSE. Department of CSE. MLR Institute of Technology, Dundigal, Hyd-500043Page 2. MLR Institute of Technology, Dundigal,

Department of CSE

55 a,d,f Cache Coherence T1 /Ch11 1,2,3,4,&5

56 a,d,f Cache Coherence T1 /Ch11 1,2,3,4,&5

9.9 MAPPING COURSE OBJECTIVES LEADING TO THE ACHIEVEMENT OF PROGRAM OUTCOMES

Course ObjectiveCourse Outcomes

a b C d e fI SII HIII S HIV SV S HVI H H

S=Supportive H=Highly Related

9.10 MAPPING COURSE OUTCOMES LEADING TO THE ACHIEVEMENT OF PROGRAM OUTCOMES

Course OutcomesProgram Outcomes

A B C D E F G H I J k L M Na H S Sb S H Sc S Sd H S S Se S H Sf H S S S S

S=Supportive H=Highly Related

9.11 OBJECTIVE BITS

UNIT I1. Consider the following sequence of micro-operations.

MBR <- PCMAR <- XPC <- YMemory <- MBRWhich one of the following is a possible operation performed by this sequence?A. Instruction fetchB. Operand fetchC. Conditional branchD. Initiation of interrupt serviceAnswer D

2. The smallest integer that can be represented by an 8-bit number in 2’s complement form isA. -256B. -128

MLR Institute of Technology, Dundigal, Hyd-500043 Page 9

Page 10: 9.12TUTORIALQUESTIONS - MLR Institute of Web viewDepartment of CSE. Department of CSE. MLR Institute of Technology, Dundigal, Hyd-500043Page 2. MLR Institute of Technology, Dundigal,

Department of CSE

C. -127D. 0Answer B

3. A RAM chip has a capacity of 1024 words of 8 bits each (1K × 8). The number of 2 × 4 decoders with enable line needed to construct a 16K × 16 RAM from 1K × 8 RAM isA. 4B. 5C. 6D. 7Answer B

4. In multiple Bus organisation, the registers are collectively placed and referred as ______.A. Set registersB. Register fileC. Register BlockD. Map registersAnswer B

5. The ISA standard Buses are used to connect,A. RAM and processorB. GPU and processorC. Harddisk and ProcessorD. CD/DVD drives and ProcessorAnswer C

6. The main advantage of multiple bus organisation over single bus is,A. Reduction in the number of cycles for executionB. Increase in size of the registersC. Better ConnectivityD. None of theseAnswer A

7. RISC Processors discouraging which control unitA. HardwiredB. Micro ProgrammingC. both D. noneAnswer B

8. A static pipeline is specified by ______________ reservation table whereas the dynamic pipeline is specified by _______________ reservation tablesA. one, more than oneB. one, oneC. more than one, more than oneD. more than one, oneAnswer A

9. Assume that the time required for the 5 functional units whic operate in each of the 5 cycles are:10ns, 8ns,10ns, 10ns and 7ns. Assume that the pipelining adds 1 ns of overhead.Find the speedup vs the single data path.A. 4.1 times B. 4.5 timesC. 4.8 timesD. 3.7 times

MLR Institute of Technology, Dundigal, Hyd-500043 Page 10

Page 11: 9.12TUTORIALQUESTIONS - MLR Institute of Web viewDepartment of CSE. Department of CSE. MLR Institute of Technology, Dundigal, Hyd-500043Page 2. MLR Institute of Technology, Dundigal,

Department of CSE

Answer A10. The method for updating the main memory as soon as word is removed from the

cache is calledA. Write-throughB. Write - backC. Protected writeD. Cache WriteAnswer B

UNIT - II1. __________ is the bootleneck, when it comes computer performance.

A. Memory access timeB. Memory cycle timeC. DelayD. LatencyAnswer B

2. The minimum time delay between two successive memory read operations is ____.A. Cycle timeB. LatencyC. DelayD. None of the aboveAnswer A

3. A memory organization that can hold upto 1024 bits and has a minimum of address lines can be organized into_____________A. 128 x 8B. 256 x 4C. 512 x 2D. 1024 x1Answer D

4. The number of external connections required in 16x8 memory organization is________A. 14B. 19C. 15D. 12Answer A

5. The larger memory placed between the primary cache and the memory is called____A. Level 1 cacheB. Level 2 cacheC. EEPROMD. TLBAnswer B

6. The effectiveness of the cache memory is based on the property of ________.A. Locality of referenceB. Memory localizationC. Memory sizeD. None of the aboveAnswer A

7. The spatial aspect of the locality of reference means

MLR Institute of Technology, Dundigal, Hyd-500043 Page 11

Page 12: 9.12TUTORIALQUESTIONS - MLR Institute of Web viewDepartment of CSE. Department of CSE. MLR Institute of Technology, Dundigal, Hyd-500043Page 2. MLR Institute of Technology, Dundigal,

Department of CSE

A. That the recently executed instruction is executed again nextB. That the recently executed wont be executed againC. That the instruction executed will be executed at a later timeD. That the instruction in close proximity of the instruction executed will be

executed in futureAnswer D

8. The techniques which move the program blocks to or from physical memory is called asA. PagingB. Virtual memory organizationC. OverlaysD. FramingAnswer B

9. The binary address issued to data or instructions are called as ______.A. Physical addressB. LocationC. Relocatable addressD. Logical addressAnswer D

10. The type of control signal are generated based on,A. contents of the step counterB. Contents of IRC. Contents of condition flagsD. All of the aboveAnswer D

UNIT – III1. The USB device follows _______ structure.

A. ListB. HuffmannC. HashD. TreeAnswer D

2. USB is a parallel mode of transmission of data and this enables for the fast speeds of data transfers.A. TrueB. FalseAnswer B

3. The device can send a message to host by taking part in _____ for the communication path.A. ArbitrationB. PollingC. PrioritisingD. None of the aboveAnswer B

4. The devices connected to USB is assigned an ____ adrress.A. 9 bitB. 16 bitC. 7 bitD. 4 bit

MLR Institute of Technology, Dundigal, Hyd-500043 Page 12

Page 13: 9.12TUTORIALQUESTIONS - MLR Institute of Web viewDepartment of CSE. Department of CSE. MLR Institute of Technology, Dundigal, Hyd-500043Page 2. MLR Institute of Technology, Dundigal,

Department of CSE

Answer C5. Locations in the device to or from which data transfers can take place is called

____.A. End pointsB. HostsC. SourceD. None of the aboveAnswer A

6. The initial address of a device just connected to the HUB is ____ .A. AHFG890B. 0000000C. FFFFFFFD. 0101010Answer B

7. The transformation between the Parallel and serial ports is done with the help of __.A. Flip flopsB. Logic circuitsC. Shift registersD. None of the aboveAnswer C

8. The mode of transmission of data, where one bit is sent for each clock cycle is ___.A. AsynchronousB. ParallelC. SerialD. IsochronousAnswer D

9. The standard used in serial ports to facilitate communication is _____.A. RS-246B. RS-LNKC. RS-232-CD. Both a and bAnswer C

10. In serial port interface, the INTR line is connected to _____.A. Status registerB. Shift registerC. Chip selectD. None of the aboveAnswer A

UNIT – IV1. Compaction means___________

A. A technique for overcoming internal fragmentationB. A paging techniqueC. A technique for overcoming external fragmentationD. A technique for overcoming fatal errorAnswer C

2. Operating system maintains a page table for___________A. Each processB. Each thread

MLR Institute of Technology, Dundigal, Hyd-500043 Page 13

Page 14: 9.12TUTORIALQUESTIONS - MLR Institute of Web viewDepartment of CSE. Department of CSE. MLR Institute of Technology, Dundigal, Hyd-500043Page 2. MLR Institute of Technology, Dundigal,

Department of CSE

C. Each instructionD. Each addressAnswer A

3. With paging there is no__________________ fragmentationA. InternalB. ExternalC. Either type ofD. None of theseAnswer A

4. The size of a page is typically:A. variedB. power of 2C. power of 4D. None of theseAnswer B

5. Every address generated by the CPU is divided into two parts : (choose two)A. frame bitB. page numberC. page offsetD. frame offsetAnswer B,C

6. Physical memory is broken into fixed-sized blocks called ________.A. framesB. pagesC. backing storeD. None of theseAnswer A

7. The advantage of dynamic loading is that :A. a used routine is used multiple timesB. an unused routine is never loadedC. CPU utilization increasesD. All of theseAnswer B

8. If the process can be moved during its execution from one memory segment to another, then binding must be :A. delayed until run timeB. preponed to compile timeC. preponed to load timeD. None of theseAnswer A

9. The circular wait condition can be prevented byA. defining a linear ordering of resource typesB. using threadC. using pipesD. all of the mentionedAnswer A

10. For effective operating system, when to check for deadlock?A. Every time a resource request is madeB. at fixed time intervalsC. both (a) and (b)

MLR Institute of Technology, Dundigal, Hyd-500043 Page 14

Page 15: 9.12TUTORIALQUESTIONS - MLR Institute of Web viewDepartment of CSE. Department of CSE. MLR Institute of Technology, Dundigal, Hyd-500043Page 2. MLR Institute of Technology, Dundigal,

Department of CSE

D. none of the mentionedAnswer C

UNIT V1. The address of I/O device is communicated using______________

A. Data BusesB. Data LinesC. Address BusD. Status LineAnswer Address Bus

2. _________command is used to acitvate the peripheral and to inform it what to doA. Control commandB. Status commandC. Data input commandD. Data output commandAnswer Control Command

3. In asynchronous data transfer, both sender and reciver accompany____ control signalA. StrobeB. HandshakingC. Two wire controlD. Single wire controlAnswer Hand Shaking

4. _________ is used to test various status conditions in the interface and peripheralA. Control commandB. Status commandC. Data input commandD. Data output commandAnswer Status Command

5. _____________mapping uses different address space for memory and I/OA. Memory mapped I/O B. Isolated I/OC. Independent I/OD. Interrupt driven I/OAnswer Isolated I/O

6. The rate at which serial information is transmitted and is equivalent to the data transfer in bits per second is__________A. Baud rateB. Bit rateC. Control rateD. Strobe ratesAnswer Baud Rate

7. In the following which uses separate controller for data transfer________A. Programmed I/OB. Interrupt initiated I/OC. DMAD. All the equally efficientAnswer DMA

8. In polling the drawback is__________A. Cost is more complex

MLR Institute of Technology, Dundigal, Hyd-500043 Page 15

Page 16: 9.12TUTORIALQUESTIONS - MLR Institute of Web viewDepartment of CSE. Department of CSE. MLR Institute of Technology, Dundigal, Hyd-500043Page 2. MLR Institute of Technology, Dundigal,

Department of CSE

B. Hardware requiredC. Time consumingD. Maintenance is moreAnswer Time Consuming

9. Continously monitoring I/O devices is done in___________ A. Programmed I/OB. Interrupt initiated I/OC. DMAD. Memory mapped I/OAnswer DMA

10. The DMA controller acts like___________A. Primary cacheB. CPUC. Cache memoryD. RouterAnswer CPU

11. The number of basic I/O commands in IBM 370 computer IOP is_________ A. 50B. 6C. 80D. 40Answer 6

12. The number of basic I/O commands in Intel 8089 computer IOP is______ A. 50B. 6C. 80D. 40Answer 50

13. The Intel 8089 I/O processor contains the IC package of________A. 64 pinsB. 40 pinsC. 16 pinsD. 32 pinsAnswer 40 Pins

14. A processor with DMA capability that communicates with I/O devices is______A. Input Output ProcessorB. Data Communication processorC. Data communication D. Input Output programmerAnswer Input Output Processor

15. The I/O processor in IBM 370 computer is called__________A. Router B. ChannelC. DeviceD. ModemAnswer Router

16. Which of the following architectures represents the organization of a computer containing a single control unit, a processor unit and a memory unit__________A. SIMDB. MISD

MLR Institute of Technology, Dundigal, Hyd-500043 Page 16

Page 17: 9.12TUTORIALQUESTIONS - MLR Institute of Web viewDepartment of CSE. Department of CSE. MLR Institute of Technology, Dundigal, Hyd-500043Page 2. MLR Institute of Technology, Dundigal,

Department of CSE

C. SISDD. MIMDAnswer SISD

17. Interfaces to memory and I/O devices are made through___________A. Central switchB. BusesC. Data LinksD. All of the aboveAnswer Buses

18. I/O command type___________ A. ReadB. ControlC. TestD. All of the aboveAnswer Test

19. The techniques for data transfer not involving the processor__________A. Direct Memory AccessB. Programmed I/OC. Memory mapped I/OD. All of the aboveAnswer Direct Memory Access

20. In an Interrupt- driven I/O, when an interrupt is detected, details on the current processor condition is stored in_____________________A. Return Address RegisterB. Program CounterC. Program status wordD. Memory bankAnswer Return Address Register

9.12 TUTORIALQUESTIONS PART-A (SHORT ANSWER QUESTIONS)

S.No Questions

BloomsTaxonomy

Level

Program Outcome

UNIT-I1. Explain the role of program counter in Instruction execution? Understand 12. Describe the basic functional units of a computer? knowledge 13. Define memory access time. Remember 2

4. Explain memory address register (MAR) and memory data register (MDR)? Understand 1

5. State and Explain different types of addressing modes? knowledge 2

6. Describe the IEEE standard for floating point numbers for single precision number. knowledge 3

7. Discuss the single Bus architecture? Understand 28. Classify the Arithmetic Micro operations? Understand 19. Show the diagram of one stage arithmetic logic shift unit? Apply 210. State the role of the registers involved in instruction execution. knowledge 411. List out differences between Multiprocessors and Multicomputer. knowledge 312. Explain the three instruction code formats of a basic computer. Understand 5

13. Describe the instruction cycle with the help of a neat diagram. Also draw the flow chart for the same. knowledge 4

MLR Institute of Technology, Dundigal, Hyd-500043 Page 17

Page 18: 9.12TUTORIALQUESTIONS - MLR Institute of Web viewDepartment of CSE. Department of CSE. MLR Institute of Technology, Dundigal, Hyd-500043Page 2. MLR Institute of Technology, Dundigal,

Department of CSE

14. State the difference between arithmetic shift and logical shift. knowledge 3UNIT II

1. Describe the two approaches used for generating the control signals in proper sequence. Knowledge 5

2. Define the following: (a) Micro-operation (b) Micro-instruction (c) Micro- program (d) Micro-code. Remember 5

3. Explain the factors to determine the control signals? Understand 54. Discuss the features of the hardwired control? Understand 45. Define micro programmed control? Remember 36. Explain control word? Understand 57. Define micro routine and microinstruction. Remember 48. Differentiate hardwired control and micro-programmed control. Understand 39. Define control store? Remember 410. Explain the drawback of micro programmed control? Understand 6

11. Discuss the drawback of assigning one bit position to each control signals? Understand 7

12. Explain the drawback of micro programmed control? Understand 2

13. Define Memory Access time. Remember 2

UNIT III1. Define an I/O Interface? Remember 72. Describe the factors considered in designing an I/O subsystem? Knowledge 63. Explain Direct Memory Access Understand 4

4. Explain the different methods used for handling the situation when multiple interrupts occurs? Understand 8

5. Define polling? Remember 5

6. Define intra segment and inter segment program control transfer in computer organization? (near and far pointer concept) Remember 5

7. Discuss the need of interrupt controller? Understand 6

8. List the two independent mechanisms for controlling interrupt request? Knowledge 4

9. Define vectored interrupts? Remember 710. Distinguish between memory mapped I/O and I/O mapped I/O? Apply 911. Define bus. Remember 412. Discuss the necessity of an interface in memory organization? Understand 613. Define synchronous bus. Remember 214. Discuss the usage of an I/O controller. In memory organization? Understand 315. Define asynchronous bus. Remember 4

UNIT IV

1. Define Operating System? Explain the three main purposes of an operating system? Remember 9

2. Define kernel? List at least two functions of the kernel. Remember 113. Define thread? Explain about multithreading. Remember 124. Describe the process state diagram Knowledge 105. Explain the advantages of Multiprogramming Understand 136. State the advantage of multiprocessor system Knowledge 9

7. Explain the difference between multiprocessor and multiprocessing? Understand 5

8. Compare user threads and kernel threads. Analyze 119. Discuss the use of fork () and exec () system calls? Understand 1010. Explain the use of job queues, ready queues and device queues? Understand 1211. State and Explain advantages of context switch? Knowledge 1012. Define scheduler? List different types of Schedulers. Remember 913. Discuss scheduling a process? What are the types of schedules Understand 10

MLR Institute of Technology, Dundigal, Hyd-500043 Page 18

Page 19: 9.12TUTORIALQUESTIONS - MLR Institute of Web viewDepartment of CSE. Department of CSE. MLR Institute of Technology, Dundigal, Hyd-500043Page 2. MLR Institute of Technology, Dundigal,

Department of CSE

available?14. Explain about Multi-Threading Models. Understand 11

UNIT V

1. Define an I/O Interface? Remember 72. Describe the factors considered in designing an I/O subsystem? Knowledge 63. Explain Direct Memory Access Understand 4

4. Explain the different methods used for handling the situation when multiple interrupts occurs? Understand 8

5. Distinguish between memory mapped I/O and I/O mapped I/O? Apply 96. Define bus. Remember 47. Discuss the necessity of an interface in memory organization? Understand 68. Define synchronous bus. Remember 29. Discuss the usage of an I/O controller. In memory organization? Understand 310. Define asynchronous bus. Remember 411. State and explain memory mapped I/O? knowledge 712. Explain program-controlled I/O? Understand 5

PART – B LONG ANSWER QUESTIONS

S.No Questions

BloomsTaxonomy

Level

Program Outcome

UNIT I

1 Explain the functional organization of a digital computer and explain the function of each element of a computer. Understand 2

2 Discuss briefly about Floating point Representation with Example. Understand 5

3 Draw a Bus system for four registers using Multiplexers. Explain it in detail. Knowledge 2

4 Explain Binary Adder- Sub tractor with Diagram in detail. Understand 35 Draw and explain 4-bit arithmetic circuit with neat diagram. Knowledge 2

6 Discuss different applications of Logical micro-operations with Examples. Understand 2

7 Explain different Shift Micro-operations with examples. Understand 3UNIT II

1.1

Define Control memory? Explain Micro programmed Control Organization. Remember 5

2. Explain operation of control unit of basic computer with diagram. Understand 43. Explain briefly about Address Sequencing in control memory. Understand 34. Draw and Explain the Microinstruction Format. 4

5. Explain the following related to Address Sequencing. a)Conditional branching b)Mapping of Instruction Understand 6

UNIT III1. Explain the Organization of Hardwired control in detail. Understand 7

2. List the differences between hardwired control and micro programmed control. Knowledge 6

3. Explain the Organization of Micro programmed control unit in detail. Understand 8

4. Explain briefly about Micro-program Sequencer with diagram. Understand 10

5. Explain the memory hierarchy with the reference of following metrics?a) Speed b) Cost c) Size Understand 5

UNIT IV

MLR Institute of Technology, Dundigal, Hyd-500043 Page 19

Page 20: 9.12TUTORIALQUESTIONS - MLR Institute of Web viewDepartment of CSE. Department of CSE. MLR Institute of Technology, Dundigal, Hyd-500043Page 2. MLR Institute of Technology, Dundigal,

Department of CSE

1.

Compare the main memory organization schemes of contiguous- memory allocation, segmentation, and paging with respect to the following issues:a. External fragmentationb. Interna lfragmentation

c. ability to share code acrossprocesses

Understand 13

2. Differentiate between internal and external fragmentation. Which one occurs in paging scheme. Understand 10

3. Explain briefly about Paging with neat diagram. Understand 9

4. Discuss the followinga)Hierarchicalpaging b)Inverted pageTables Understand 10

5. Draw and explain the working procedure of paging hardware in detail. Knowledge 11

UNIT V1 Explain briefly about DMA Controller with block diagram Understand 3

2 Distinguish between programmed I/O and Interrupt initiated IO with example. Analyze 8

3 Discuss DMA transfer technique in detail with block diagram? Understand 44 Distinguish between memory mapped I/O and I/O mapped I/O. Analyze 65 Differentiate isolated I/O and memory mapped I/O? Analyze 4

PART – C (PROBLEM SOLVING AND CRITICAL THINKING QUESTIONS)

S.No Questions

BloomsTaxonomy

Level

Program Outcome

UNIT I

1.An 8-bit register contains the binary value 10011100.Determine the register value after an arithmetic shift right? Starting from the initial number 10011100, Determine the register value after an arithmetic shift left,and state whether there is an overflow.

Evaluate 3

2.Starting from an initial value of R=11011101, Determine the sequence of binary values in R after a logical shift-left, followed by a circular shift-right, followed by logical right and a circular shift left.

Evaluate 7

3. Illustrate the signed magnitude, signed 1’s complement, and signed 2’s complement for the decimal number 14. Apply 5

4.Register A holds the 8 bit binary number 110111001. Determine the B operand and the logic micro operation to be performed in order to change the value in A to :a) 01101101 b) 11111101

Evaluate 2

UNIT II

1 Illustrate how PSW will be effected up on execution of arithmetic expression Apply 3

2 Select suitable addressing mode based on the type of processor and no. Of cores Evaluate 5

3 Design Arithmetic logic unit for 4 bit register supporting 16 operations Create 6

UNIT III

1 Micro programmed control unit is more flexible to changes and is more appropriate for CISC architecture. Justify? Evaluate 5

2 Design a logic circuit to perform address sequencing for basic computer organization Create 6

3 Design a control memory architecture for basic computer using semi conductor technology Create 6

UNIT IV

MLR Institute of Technology, Dundigal, Hyd-500043 Page 20

Page 21: 9.12TUTORIALQUESTIONS - MLR Institute of Web viewDepartment of CSE. Department of CSE. MLR Institute of Technology, Dundigal, Hyd-500043Page 2. MLR Institute of Technology, Dundigal,

Department of CSE

1 Analyze the performance of Booth’s algorithm with conventional multiplication algorithm Analyze 4

2 Apply non restoring division on binary data and design a logic to detect divide by zero condition Apply 3

3Explain floating point representation using IEEE format and normalization and analyze how it varies from processor to processor

Analyze 3

UNIT V

1 Does virtual memory is needed in today’s computer with huge amounts of RAM being available? Justify Evaluate 5

2Analyze the performance of cache memory with respect to mapping techniques and suggest the most affective cache mapping to improve hit ratio.

Analyze 4

3 Does cycle stealing will improve the performance of the computer or not? Justify Evaluate 5

MLR Institute of Technology, Dundigal, Hyd-500043 Page 21

Page 22: 9.12TUTORIALQUESTIONS - MLR Institute of Web viewDepartment of CSE. Department of CSE. MLR Institute of Technology, Dundigal, Hyd-500043Page 2. MLR Institute of Technology, Dundigal,

Department of CSE

10. DIGITAL LOGIC DESIGN(A10507)

10.0 COURSE DESCRIPTION

Course Code A30407Course Title Digital Logic Design

Course StructureLectures Tutorials Practical Credits

4 1 - 4Course Coordinator A. Deepthi. Assistant professorTeam of Instructors M. Srikanth. Assistant professor

10.1 COURSE OVERVIEW: This course provides in-depth knowledge of switching theory and the design

techniques of digital circuits, which is the basis for design of any digital circuit. Such digital ciruits may be strictly combinational logic, in which their output state is only a function of the present state of their inputs; or may also contain sequential elements, where the present state depends on the present state and past states; in that sense, sequential circuits are said to include "memory" of past states. Switching circuit theory is applicable to the design of telephone systems, computers, and similar systems. This course is presented to students by power point projections, lecture notes, course handouts, Assignments, Objective and subjective tests.

10.2 PREREQUISITES:

Level Credits Periods / Week Prerequisites

UG 4 4 Number systems, Digital logic design, Concepts of state machines using flipflops.

10.3 MARKS DISTRIBUTION:

Session Marks University EndExam Marks Total Marks

There shall be 2 Mid Term Examinations. Each Mid Term Examination consists of a Subjective Test and an Objective Test. The Subjective Test is for duration of 1 hr and the Objective Test is for duration of 30 minutes. The Objective Test consists of 10 multiple choice and 10 fill in the blanks type questions. The student has to answer all the questions and each question carries Half Mark. The subjective test is for 10 marks and the objective test will be for 10 marks. Subjective test in midterm examinations shall contain 4 questions, with each question having part a) and part b). Each question will carry 5 marks and the student needs to answer any 2 questions. First midterm examination shall be conducted for the first four units of syllabus and second midterm examination shall be conducted for the remaining four units. The objective question paper and the key will be received from JNTUH University. Five marks are earmarked for assignments. There shall be two assignments and the marks shall be awarded considering the best of two assignments in each course. Marks shall be awarded considering the best of two Mid Term Examinations in each course reason whatsoever, will get Zero Mark (s)

75 100

10.4 EVALUATION SCHEME:

MLR Institute of Technology, Dundigal, Hyd-500043 Page 22

Page 23: 9.12TUTORIALQUESTIONS - MLR Institute of Web viewDepartment of CSE. Department of CSE. MLR Institute of Technology, Dundigal, Hyd-500043Page 2. MLR Institute of Technology, Dundigal,

Department of CSE

S. No Component Duration Marks1 I Mid Examination 90minutes 202 I Assignment 53 II Mid Examination 90minutes 204 II Assignment 55 External Examination 3 hours 75

10.5 a) COURSE OBJECTIVES: I. Discuss the basic techniques for the design of digital circuits and fundamental

concepts used in the design of digital systems.II. Describe the common forms of number representation in digital electronic circuits

and to be able to convert between different representations.III. Discuss the combinational circuit’s using simple logical operations.IV. Discuss combinational logic circuits, sequential logic circuits.V. Illustrate the concepts of sequential circuits , enabling students to analyze sequential

systems in terms of state machinesVI. Explore the techniques to implement synchronous state machines using flip-flops.

b) COURSE OUTCOMES: a) Able to understand the basic digital logic fundamentals such as numbering systems,

binary codes and Boolean algebra.b) Able to Understand the basic building blocks of digital systems like gates and

minimization of Boolean expressions using K-map methodc) Able to understand the concept of sequential circuits d) Able to Design counters with the knowledge of combinational and sequential circuits.e) Able to Design the state diagrams with the knowledge of Mealy and Moorecircuits and

algorithmic state machines for binary multipliers.

10.6 HOW PROGRAM OUTCOMES AREASSESSED:

S. No. Outcome Level Proficiency assessed by

A.An ability to apply the knowledge of mathematics, science, and engineering to solve Electronics and communications engineering problems.

H Assignments

B. An ability to design and conduct engineering experiments, as well as to analyze and interpret data. H Assignments

C. An ability to design and construct a hardware and software system, component, or process to meet desired needs, within realistic constraints. S --

D. An ability to function on multi – disciplinary teams. H DesigningExercises

E. An ability to identify, formulate and solve engineering problems. S Designing

F. An understanding of professional, social and ethical responsibility N --

G. An ability to communicate effectively. N --

H. The broad education necessary to understand the impact of engineering solutions in a global, economic, environmental, and societal context. S Prototype

Models

I. An ability to recognize the need for and an ability to engage in life – long learning. N --

MLR Institute of Technology, Dundigal, Hyd-500043 Page 23

Page 24: 9.12TUTORIALQUESTIONS - MLR Institute of Web viewDepartment of CSE. Department of CSE. MLR Institute of Technology, Dundigal, Hyd-500043Page 2. MLR Institute of Technology, Dundigal,

Department of CSE

J. An ability to gain knowledge of contemporary issues. SDocument

Preparation,Presentation

K. An ability to use the techniques, skills, and modern engineering tools necessary for engineering practice. S Assignments

L. Graduates are able to participate and succeed in competitive examination like GRE, GATE, TOEFL, GMAT etc. H Assignments

M.The use of current application software’s; the design and use of circuits; and the analysis, design, testing, and documentation of Analog and Digital circuits for the use in Communications engineering.

H Presentation

N.The basic knowledge of electronics, electrical components, computer architecture and applications of microcomputer systems, communications needed in data transport.

H Assignments

N=None S=Supportive H=Highly Related

10.7 SYLLABUS

UNIT - IDIGITAL SYSTEMS AND BINARY NUMBERS: Digital systems, binary numbers, number base conversions, octal and hexadecimal numbers, complements, signed binary numbers, binary codes, error detection and error correction codes.BOOLEAN ALGEBRA AND LOGIC GATES: Basic definitions, axiomatic definition of Boolean algebra, basic theorems and properties of Boolean algebra, Boolean functions, canonical and standard forms, other logic operations, digital logic gates.UNIT - IIGATE LEVEL MINIMIZATION: The k-map method, four-variable map, five-variable map, product of sums simplification, don’t-care conditions, NAND and NOR implementation, determination and selection of Prime Implicants, Essential and Non essential prime Implicants.UNIT - IIICOMBINATIONAL CIRCUITS: Design procedure, Binary Adder, Binary Sub tractor, Binary Multiplier, Magnitude Comparator, Decoders, Encoders, Multiplexers, and Demultiplexers.UNIT - IVSYNCHRONOUS SEQUENTIAL LOGIC: Sequential circuits, latches, flip-flops, analysis of clocked sequential circuits, State reduction and assignment, design procedure.REGISTERS AND COUNTERS: Registers, shift registers, ripple counters, synchronous counters, counters with unused states, ring counter, Johnson counter.UNIT - VMEMORY AND PROGRAMMABLE LOGIC: Introduction, Random access memory, memory decoding, error detection and correction, read only memory, programmable logic array, programmable array logic, sequential programmable devices.TEXT BOOKS:1. M. Morris Mano, Michael D. Ciletti (2008), Digital Design, 4th edition, Pearson

Education Inc, India.

REFERENCE BOOKS:1. Zvi. Kohavi (2004), Switching and Finite Automata Theory, Tata McGraw Hill, India.2. C. V. S. Rao (2009), Switching and Logic Design, 3rd Edition, Pearson Education,

India.3. Donald D. Givone (2002), Digital Principles and Design, Tata McGraw Hill, India4. Roth (2004), Fundamentals of Logic Design, 5th Edition, Thomson, India.

MLR Institute of Technology, Dundigal, Hyd-500043 Page 24

Page 25: 9.12TUTORIALQUESTIONS - MLR Institute of Web viewDepartment of CSE. Department of CSE. MLR Institute of Technology, Dundigal, Hyd-500043Page 2. MLR Institute of Technology, Dundigal,

Department of CSE

10.8 COURSE PLAN: At the end of the course, the students are able to achieve the following Course Learning Outcomes.

Lecture No. Course Learning Outcomes Topics to be covered Reference

1-4 Understand bse conversion methods and arithmetic operations

Introduction to digital systems, base conversion methods binary and decimal ,octal and hexadecimal

T1

5-6 Understand the importance of complementation of numbers.

Complements of Numbers:1’s complement Complements of Numbers:2’s complement T1

7-8 Identify the different types ofBinary and decimal codes Codes- Binary Codes Signed binary numbers T1

9-10Understand Unit Distance Codes& Alpha Numeric Codes Error Detecting Codes

Error Correcting CodesError Detecting Codes T1

11-13 Identify Error Correcting Codes and Properties of theorems

Basic Theorems and Properties, Switching Functions T1

14-16Understand the difference between Canonical and Standard Form and importance of universal gates

Canonical and Standard Form, Algebraic Simplification of Digital Logic, Gates, Properties of XOR Gates, Universal Gates

T1

17-18 Understand Multilevel NAND and NOR realizations

Multilevel NAND realizations Multilevel NOR realizations T1

19-21 Problems on base conversions Tutorial, class test. T1

22-25 Learn the different types of k-mapsThe Minimization with theorem The Karnaugh Map Method Five Variable Maps, Six Variable Maps

T1

26-28 Understand Prime and Essential Implications and tabular methods

Prime and Essential Implications, Don’t Care Map Entries Using the Maps for SimplifyingTabular Method

T1

29-30 Learn the Implementations of gates NAND and NOR implementation T1

31-33Understand the Design procedure of combinational circuitsArithmetic Circuits.

Design the Combinational circuits of Arithmetic Circuits. T1

34-36 Designing of combinational circuits Decoders, Encoders, comparators, Multiplexers, De-multiplexers T1

37-39 Designing on combinational circuits Tutorial, Class test T1

40-41

Identify the difference between combinational and sequential circuits and Learn basic concepts of sequential circuits.

Introduction, Basic Architectural Distinctions between Combinational and Sequential circuits, The Binary Cell, Fundamentals of Sequential Machine Operation, The Flip-Flop

T1

42-43 Understand the flip-flops and their importance.

The D-Latch Flip-Flop, The “Clocked T” Flip-Flop, The “ Clocked J-K” Flip-Flop Design of a Clocked Flip-Flop

T1

44 Understand State Diagram using sequential circuits.

Introduction, State Diagram Analysis of Synchronous Sequential Circuits T2

45-47Learn different Approaches to the Design of Synchronous Sequential Finite State Machines

Approaches to the Design of Synchronous Sequential Finite State Machines T2

48-49 Describe Design Aspects and State Reduction Design Aspects, State Reduction T2

50 Learn the Realization using Flip-Flops and design of counters

Realization using Flip-FlopsCounters - Design of Single mode Counter T2

51 Understand Finite state machine- Finite state machine-capabilities and limitations T2

MLR Institute of Technology, Dundigal, Hyd-500043 Page 25

Page 26: 9.12TUTORIALQUESTIONS - MLR Institute of Web viewDepartment of CSE. Department of CSE. MLR Institute of Technology, Dundigal, Hyd-500043Page 2. MLR Institute of Technology, Dundigal,

Department of CSE

capabilities and limitations

52-53 Learn the concepts of Mealy and Moore models Mealy and Moore models T2

54-58 Understand the different types of Counters and their applications

Ripple Counter, Ring Counter, Shift Register, Shift Register Sequences, Ring Counter, Johnson counter.

T2

59 Implement different types of flip-flops and counters Tutorial Class test T2

60 Understand the Programmable logic devices Introduction, T2

61-64 Understand the behavoiur of memory Random access memory, memory decoding, read only memory T2

65 Understand the correction of codes error detection and correction T2

66 Understand the different logic devices

programmable logic array, programmable array logic, sequential programmable devices T2

67-69 Understand Different PLA’s and PAL’s Tutorial, Class test T2

10.9 MAPPING COURSE OBJECTIVES LEADING TO THE ACHIEVEMENT OF PROGRAM OUTCOMES

Course Outcomes

Program OutcomesA B C D E F G H I J K K M N

1 2 3 4 5

S = Supportive H = Highly Related

10.10 MAPPING COURSE OUTCOMES LEADING TO THE ACHIEVEMENT OF ROGRAM OUTCOMES:

Coursecode

II-I SEMESTERSwitching theory and logic design A B C D E F G H I J K L M N

A30407

CO1:Able to understand the basic digital logic fundamentals such as numbering systems, binary codes and Boolean algebra.

CO2: Able to Understand the basic building blocks of digital systems like gates and minimization of Boolean expressions using K-map method

CO3: Able to understand the concept of sequential circuits

CO4: Able to Design counters with the knowledge of combinational and sequential circuits.

MLR Institute of Technology, Dundigal, Hyd-500043 Page 26

Page 27: 9.12TUTORIALQUESTIONS - MLR Institute of Web viewDepartment of CSE. Department of CSE. MLR Institute of Technology, Dundigal, Hyd-500043Page 2. MLR Institute of Technology, Dundigal,

Department of CSE

CO5:Able to Design the state diagrams with the knowledge of Mealy and Moorecircuits and algorithmic state machines for binary multipliers.

S= Supportive H= Highly relative

10.11 OBJECTIVEQUESTIONS

UNIT-I1. Gray code belongs to the class

A. Cyclic codesB. Reflected codesC. BothD. None

2. Which of the following are Self Complementary1. (6,4,2,-3)2. (2,4,2,1)3. (8,4,2,1)4. (3,3,2,1)A. 1&2B. 3C. 1,2&4D. 1&3

3. Excess-3 of BCD is obtained by adding ______ to BCD codeA. 1100B. 0011C. 1001D. 0110

4. For a code to be error detecting, the minimum distance between two successive code words isA. zeroB. fiveC. twoD. infinity

5. The number of k parity digits need to satisfy the inequalityA. 2k ≥ m+k-1B. 2k ≥ m+kC. 2k ≥ m+k+1D. 2k ≥ m-k

6. 23+44+14+32=223. What would be the base of the above systemA. b=3B. b=4C. b=5D. b=5

7. 8421 and Excess-3 are A. WeightedB. ReflectiveC. AlphanumericD. sequential

9. Binary equivalent of gray number 1110 is

MLR Institute of Technology, Dundigal, Hyd-500043 Page 27

Page 28: 9.12TUTORIALQUESTIONS - MLR Institute of Web viewDepartment of CSE. Department of CSE. MLR Institute of Technology, Dundigal, Hyd-500043Page 2. MLR Institute of Technology, Dundigal,

Department of CSE

A. 1011B. 1010C. 1100D. 0101

10. 1010P; for odd parity p=?A. 0B. 1C. bothD. none

11 Even parity hamming code for 1101A. 1100110B. 1001100C. 1010110D. 1010101

12. FACE16 to binaryA. 1111011101001B. 1111101011001110C. 11111111100001D. 0111100000000110

13. (0.4375)10 to binaryA. 0.0011B. 0.10010C. c. 0.0111D. 11.0011

14. (10011.11)2 = X16; X=?A. A.CB. 13.AC. 12D. 13. C

15. (1431)8 = (?)10

A. 793B. 344C. 391D. 395

16. 11001101.0101 = (?)8

A. 315.22B. 315.24C. 410.22D. 344.26

UNIT-II1. The main theorem that is being applied in the K-map simplification is

A. Demorgan’s theoremB. Consensus theoremC. Combining theorem, Aa+Aa1=AD. None

2. The number of calls in a 4 variable K-map isA. 4B. 16C. 8

MLR Institute of Technology, Dundigal, Hyd-500043 Page 28

Page 29: 9.12TUTORIALQUESTIONS - MLR Institute of Web viewDepartment of CSE. Department of CSE. MLR Institute of Technology, Dundigal, Hyd-500043Page 2. MLR Institute of Technology, Dundigal,

Department of CSE

D. 33. For each cell, number of adjacent cells in a 4 variable K-map is

A. 2B. 4C. 3D. 8

4. Which of the following code is used in K-map for representing the mintermsA. 8421B. BCDC. Excess-3D. Gray code

5. The minterm corresponding to decimal number 13 isA. ABCDB. A+B+C1+DC. A1+B+C+DD. AB C1D

6. Six variable function contain_______ number of cells in a K-mapA. 64B. b. 32C. c. 16D. d. 8

7. What is the decimal position of the minterm A1B1C1D1 in the K-mapA. 2B. 0C. 15D. 14

8. If f(A,B,C,D)=1 then the K-map contains _________ number of logic 1’s isA. 4B. 8 C. 16D. 32

9. In Tabular method, two terms from adjacent groups are combinable if their binary representation differs by a ______ digit in the same positionA. SingleB. TwoC. FourD. None

10. In a tabular method the minimal expression of a function contains _________A. Only prime implicantsB. Prime implicants and essential prime implicantsC. Only essential prime implicantsD. All variables

11. In a 4 variable K-map, the function contains all minterms, then the minimal expression is _A. AB. 1C. 0D. Don’t care

12. Looping a pair of adjacent 1’s in a K-map eliminates _________ number of variables

MLR Institute of Technology, Dundigal, Hyd-500043 Page 29

Page 30: 9.12TUTORIALQUESTIONS - MLR Institute of Web viewDepartment of CSE. Department of CSE. MLR Institute of Technology, Dundigal, Hyd-500043Page 2. MLR Institute of Technology, Dundigal,

Department of CSE

A. 1 B. 2C. N D. n-1

13. In a n-variable K-map, after looping a quad of adjacent 1’s, the resultant term contains ____________A. 1B. 2C. N-1 D. N-2

14. The given maxterm is A+B+C, its equivalent binary represented isA. 101B. 010C. 111D. 000

15. The given maxterm is A+B+C, its equivalent binary represented isA. 101B. 010C. 111D. 000

16. A function F(A,B,C) contains minterms 1,2,3,5,6,7, its complement containsA. Σm (0,4)B. Σm(1,2,3,5,6,7)C. ПM (1,2,3,5,6,7)D. ПM (0,4)

UNIT-III1. Flipflop is a ______ element.

A. storage B. memoryC. bothD. none

2. In a SR FF, if S=R=1 __________.A. 0B. 1C. toggleD. Is not permitted

3. In a JK FF if J=K=1, its Q output will be _________ when clock pulse is applied.A. QB. Q1

C. 0D. 1

4. Master slave configuration is used in a JK FF to eliminate ________A. togglingB. clockC. presetD. race around

5. In a T FF, The Q output _______ when T=0 and clock pulse is applied.A. 0B. 1

MLR Institute of Technology, Dundigal, Hyd-500043 Page 30

Page 31: 9.12TUTORIALQUESTIONS - MLR Institute of Web viewDepartment of CSE. Department of CSE. MLR Institute of Technology, Dundigal, Hyd-500043Page 2. MLR Institute of Technology, Dundigal,

Department of CSE

C. togglesD. does not change

6. The tabulation specifying inputs required for a FF to change from the present state to a specified next state is known as __________A. truth tableB. excitation tableC. bothD. None

7. The basic memory element in a digital circuitA. consists of a NAND gateB. consists of a NOR gateC. is a flipflopD. all of the above

8. A flip flop can store A. one bit of dataB. two bits of dataC. three bits of data D. any number of bits of data

9. The characteristic equation of a JK flipflop is______________10. In sequential circuits the present input depends on___________.

UNIT-IV1. The number of flip-flops required for decade counter is

A. 3B. 4C. 5D. 10

2. The maximum number that can be obtained by aripple counter using five flip-flops isA. 32 B. 5 C. 16 D. 31

3. In a counter circuit consisting of four J-k flip-flpos,all the flip-flops get triggered simultaneously. This counter circuitA. is a combinational circuit B. is an asynchronous circuitC. is a synchronous circuit D. Maybe a combinational or a sequential circuit.

4. The design of a clocked sequential circuit requires A. the state reduction B. the state assignmentC. the design of next state decoder D. All of the above.

5. A sequential circuit with ten states will haveA. 10 flip-flops B. 5 flip-flops C. 4 flip-flops D. 0 flip-flops

6. In a sequential circuit design, state reduction is done for designing the circuit with

MLR Institute of Technology, Dundigal, Hyd-500043 Page 31

Page 32: 9.12TUTORIALQUESTIONS - MLR Institute of Web viewDepartment of CSE. Department of CSE. MLR Institute of Technology, Dundigal, Hyd-500043Page 2. MLR Institute of Technology, Dundigal,

Department of CSE

A. a minimum number of flip-flops B. a minimum number of gatesC. a minimum number of gates and memory elements D. none of the above

7. For a design finite state machine K-maps can be used for minimizing theA. excitation expressions of flip-flposB. number of flip-flopsC. output logic expression D. excitation and output logic expression

8. A finite state machine A. is the same as a cocked sequential circuitB. consist of combinational logic circuits onlyC. Consist of electrical motors.D. does not exist in practise

9. The number of director arcs eliminating from any state in a state diagram isA. 2n,where n is number of inputs B. independent of the number of inputsC. an arbitrary number D. 2n,where n is number of flip-flops

10. The number of directed arcs terminating on any state of a state diagram is A. 2n,where n is number of inputsB. 2n,where n is number of flip-flops in the circuitC. independent of number of inputsD. dependent on the number of output

UNIT-V1. ASM can be implemented using flipflops and ___________ circuits.2. The moore type of outputs are represented inside the ___________ in an ASM chart.3. Unconditional outputs are _________ type.4. The data processind path is commonly referred to as the ______________ path.5. A row in the state table is the same as a ______________ in an ASM chart.6. Mealy type of outputs are ________________7. Moore type of outputs are______________8. An ASM chart can be implemented using flipflops and _______________9. _________ types of outputs are referred to as unconditional outputs..10. A path through an ASM block from entry to exit is referred to as a_____________

10.12 TUTORIAL QUESTIONS BANK

S.No Question

BloomsTaxonomy

Level

CourseOutcome

UNIT-I

1 Discuss about number system the number system and their conversions. synthesis(Level-6) 1

2 Prove all the Boolean algebra expressions. Evaluate(Level-5) 2

MLR Institute of Technology, Dundigal, Hyd-500043 Page 32

Page 33: 9.12TUTORIALQUESTIONS - MLR Institute of Web viewDepartment of CSE. Department of CSE. MLR Institute of Technology, Dundigal, Hyd-500043Page 2. MLR Institute of Technology, Dundigal,

Department of CSE

3Simplify the following Boolean functions to minimum number of literals: i. ( a + b )’ ( a’ + b’ )’

ii. y(wz’ + wz) + xyAnalyzing(Level-4) 1

4 Test the following Hamming code sequence for 11 bit message and correct it if necessary (1010010111 01011).

Analyzing(Level-4) 2

5Develop three possible ways to express the function F = A 1B1D1+ A1B1C1D1 + A1BD + ABC1D with eight or less literals.

Applying(Level-3) 1

UNIT-II

1Simplify the function using Karnaugh map method

F (A,B,C,D) =Σ(4,5,7,12,14,15)+Σd(3,8,10).Analyzing(Level-4) 3

2solve the given function using tabular minimization methodF(A,B,C,D)=П(0,1,3,4,5,6,7,8,9)+d(10,11,12,13,14,15).

synthesis(Level-6) 3

3Develop a combinational circuit is specified by the following two Boolean functions Design the circuit with a decoder and basic gates.

F = Σ m (1,5,9,15)

Applying(Level-3) 2

4Explain the schematic circuit for a BCD-to-decimal decoder. Give the truth-tablefor the same.

Evaluate(Level-5) 2

5simplify the following function using K- map and implement it in AOI logic as well as NOR logic F= ПM(0, 1, 2, 3, 4, 7)

Analyzing(Level-4) 3

UNIT-III

1Develop the logic diagram of a SR latch using NOR gates. Explain its operation using excitation table.

Applying(Level-3) 5

2Determine the characteristic equation for the complement out put of a JK flipflop is Q′ (t + 1) = J ‘Q′ + kQ.

Evaluate(Level-5) 5

3 Discuss about the FF’s and their truth tables and excitation tables. synthesis(Level-6) 5

4 Simplify master slave JK FF Analyzing(Level-4) 5

Construct T-FF using JK Applying(Level-3) 5

UNIT-IV

1Build the logic diagram of a 4 bit binary ripple counter using positive edgetriggering.

Applying(Level-3) 2

2 By analyzing a shift register, how do you obtain a circular shift? Analyzing(Level-4) 2

3 Determine MOD-6 counter using T-FF Evaluate(Level-5) 2

4 Function the terms 1.State diagram2.State reduction

Analyzing(Level-4) 2

5 Discuss the following 1. Jhonson counter2. Ripple counter synthesis(Level-6) 2

UNIT-V

1 Explain about Random access memory Evaluate(Level-5) 4

MLR Institute of Technology, Dundigal, Hyd-500043 Page 33

Page 34: 9.12TUTORIALQUESTIONS - MLR Institute of Web viewDepartment of CSE. Department of CSE. MLR Institute of Technology, Dundigal, Hyd-500043Page 2. MLR Institute of Technology, Dundigal,

Department of CSE

2 Discuss how the memory is decoded synthesis(Level-6) 5

3 Assume the codes and explain the error correction and detection Analyzing(Level-4) 5

4 Explain the read and write control in read only memory Evaluate(Level-5) 5

5 Explain the different types of programmsble logic devices Evaluate(Level-5) 5

10.13 ASSIGNMENT QUESTIONS

S.No Question

BloomsTaxonomy

Level

CourseOutcome

Assignment- I

1 Build and Convert(2598.675)10 to hexadecimal Applying(Level-3)

1

2 Classify and Subtract 101011 from 111001 using 2’s complement method Analyzing(Level-4)

1

3 Deduct and Perform decimal addition in 8-4-2-1 BCD 24 +18 Evaluate(Level-5)

1

4 Modify and Minimize the Boolean expression (A+B+C’)(A+B’+C’)(A’+B+C’)(A’+B’+C’)

synthesis(Level-6) 1

5 Deduct and Convert(2AC5.D) to decimal, octal and binary Evaluate(Level-5)

2

UNIT-II

1 Simplify the following boolean function by using a prime implicant method F(A,B,C,D)= ∑m(0,2,3,6,7,8,10,12,13)

Analyzing(Level-4) 3

2 Decide and reduce the following function using K-map techniquef(A,B,C,D)=∑m(0,7,8,9,10,12)+∑d(2,5,13)

Evaluate(Level-5) 3

3Select and implement the following Boolean functions using decoder and OR gates:F1(A,B,C,D)=∑(2,4,7,9)F2(A,B,C,D)=∑(10,13,14,15).

Applying(Level-3) 3

4 Design full-adder using two half adders synthesis(Level-6)

3

5 Design 4-bit parallel adder and subtractor with example. synthesis(Level-6)

2

UNIT-III

1 conclude the difference between latch and flipflop Evaluate(level-5)

5

2 Examine the ckt diagram of 4 bit ring ring counter using D flipflops and explain its operation with the help of bit pattern. Analyzing 5

3 solve the transition table for the following flip flopsi)RS flip flop ii) J-K flip flop iii)T flip flop Applying

5

4 Determine and convert SR flipflop to JK flipflop and design the cricuit. Evaluate(level-5)

4

5 Discuss different types of triggering leve Synthesis(level-6)

5

UNIT-IV

1 Design mod-5 synchronous counter using J-K FF Synthesis(level-6)

2

MLR Institute of Technology, Dundigal, Hyd-500043 Page 34

Page 35: 9.12TUTORIALQUESTIONS - MLR Institute of Web viewDepartment of CSE. Department of CSE. MLR Institute of Technology, Dundigal, Hyd-500043Page 2. MLR Institute of Technology, Dundigal,

Department of CSE

2 Compare synchronous and Asynchronous counter. Evaluate(level-5)

2

3 Explain Ring counter using shift register. Evaluate(level-5)

2

4 Build the synchronous sequential circuits? Design synchronous modulo-10 counter using D flip-flop .

Applying(Level-3)

5

5

Analyze the state table for the following state diagram

Analyzing(Level-4) 2

UNIT-V

1 Explain about Random access memory Evaluate(Level-5) 5

2 Explain how the memory is decoded synthesis(Level-6)

5

3 Assume the codes and explain the error correction and detection Analyzing(Level-4) 5

4 Explain the read and write control in read only memory Evaluate(Level-5)

5

5 Explain the different types of programmsble logic devices Evaluate(Level-5)

5

MLR Institute of Technology, Dundigal, Hyd-500043 Page 35

Page 36: 9.12TUTORIALQUESTIONS - MLR Institute of Web viewDepartment of CSE. Department of CSE. MLR Institute of Technology, Dundigal, Hyd-500043Page 2. MLR Institute of Technology, Dundigal,

Department of CSE

11. ELECTRONIC DEVICES (A10470)

11.0 COURSE DESCRIPTION

Course Code A10470Course Title ELECTRONIC DEVICES

Course StructureLectures Tutorials Practical Credits

3 1 - 3Course Coordinator E. Naresh, Asst. ProfTeam of Instructors K.Naveen, DV.Surya chanrababu, M.Raj Lahari, Leela kumar

11.1 COURSE OVERVIEW: This course covers fundamental topics that are common to a wide variety of

electronic engineering devices and systems. The topics include an introduction to semiconductor devices and their applications. The course creates the background in the physics of the compound semiconductor-based electronic devices and also prepares students to advanced courses in electronics. This course provides a basis for students to continue education by undertaking advanced study and research in the variety of different branches of semiconductor device applications

11.2 PREREQUISITE(S):

Level Credits Periods / Week PrerequisitesUG 3 4 Physics of Semiconductors

11.3 COURSE ASSESSMENT METHODS

Session Marks University EndExam Marks Total Marks

There shall be two midterm examinations. Each midterm examination consists of essay paper, objective paper and assignment.The essay paper is for 10 marks of 60 minutes duration and shall contain 4questions. The student has to answer 2 questions, each carrying 5 marks.The objective paper is for 10 marks of 20 minutes duration. It consists of 10multiple choice and 10 fill-in-the blank questions, the student has to answer all the questions and each carries half mark.First midterm examination shall be conducted for the first two and half units of syllabus and second midterm examination shall be conducted for the remaining portion.Five marks are earmarked for assignments. There shall be two assignments in every theory course. Assignments are usually issued at the time of commencement of the semester. These are of problem solving in nature with critical thinking.Marks shall be awarded considering the average of two midterm tests in each course.

75 100

MLR Institute of Technology, Dundigal, Hyd-500043 Page 36

Page 37: 9.12TUTORIALQUESTIONS - MLR Institute of Web viewDepartment of CSE. Department of CSE. MLR Institute of Technology, Dundigal, Hyd-500043Page 2. MLR Institute of Technology, Dundigal,

Department of CSE

11.4 EVALUATION SCHEME:

S. No Component Duration Marks

1 I Mid Examination 80minutes 20

2 I Assignment 5

3 II Mid Examination 80minutes 20

4 II Assignment 5

5 External Examination 3 hours 75

11.5 a) COURSE OBJECTIVES: I. To understand the dynamics of electrons and the principle of operation of CRO and

its applications.II. To understand the physics of semiconductor electronic devices, the characteristics

and their equivalent models.III. To understand the mechanism of flow of current through the p-n junction and

relating this phenomena to the characteristics and operation of the diodes, bipolar and unipolar transistors.

IV. To understand the internal working of the regulated power supply which includes characteristic parameters of rectifiers with and without filters using Zener regulation.

V. To understand the concept of biasing in BJT and JFET so as to able to analyze advanced electronic circuits.

b) COURSE OUTCOMES: After completing this course, the student will be able to:a) To apply the operating knowledge of major electronic devices like amplifiers,

oscillators & advanced analog circuits to identify, formulate & solve Engineering problems by making use of modern software/hardware tools.

b) Student can have the knowledge of internal physical behavior of electronic devices.c) Student can understand how to design and analyze various rectifiers, filter circuits.d) Able to design an amplifier circuit with proper biasing techniques (BJT and FET).e) Student can learn about Field effect transistor (FET) and analyze mosfet characteristics

which are useful to design analog and digital circuits.

11.6 HOW PROGRAM OUTCOMES ARE ASSESSED:

S. No. Outcome Level Proficiency

assessed by

A.An ability to apply knowledge of mathematics, science and engineering fundamentals to the conceptualization of engineering models (Fundamental Engineering Analysis Skills).

H Assignments, Exercises

B. An ability to design and conduct experiments, as well as analyze and interpret the data (Information retrieval skills). H Hands on Practice

Sessions

C.

An ability to design, implement and evaluate an electronics & communication engineering based system, component are process to meets desired needs within realistic constraints such as economic, environmental, social, political, ethical, health and safety, manufacturability and sustainability (Creative Skills).

S Lab Sessions

MLR Institute of Technology, Dundigal, Hyd-500043 Page 37

Page 38: 9.12TUTORIALQUESTIONS - MLR Institute of Web viewDepartment of CSE. Department of CSE. MLR Institute of Technology, Dundigal, Hyd-500043Page 2. MLR Institute of Technology, Dundigal,

Department of CSE

D. An ability to function effectively as an individual and as a member or a leader in multidisciplinary teams (Team Work). N Group

Discussions

E.An ability to identify, formulate and apply appropriate techniques, resources and to solve complex electronics & communication engineering problems (Engineering Problem Solving Skills).

H Design Exercises

F. An understanding of professional ethics and responsibilities of engineering practice (Professional Integrity). N --

G.

An ability to communicate effectively on complex electronics and communication engineering activities with the engineering community and society at large such as writing effective reports and making effective presentations (Communication Skills).

N

Seminars, Document

Preparation and Presentation

H.Understanding of the impact of engineering solutions in a global, economic, environmental and societal context (Engineering impact assessment skills).

N Discussions

I.An ability to engage in life-long learning and an understanding of the need to keep current of the developments in the specific field of practice (Continuing education awareness).

S Seminars Discussions

J.Knowledge of contemporary issues like increased use of portable devices, rising health care costs and etc. which influence engineering design (Social awareness).

SWorkshop, Mini

Projects, Prototypes

K.An ability to use current techniques, skills and modern engineering tools necessary to analyze electronics & communication engineering practice (Practical engineering analysis skills).

HDesign Exercises, Seminars, Paper

Presentations

L.An ability to apply creativity in design and development of electronic circuits, equipment, components, sub-systems and systems (Software and Hardware Interface).

S

Design Exercises, Development of Prototypes, Mini

Projects

M.

An ability to recognize the importance of professional developments by pursuing post graduate studies or facing competitive examinations that offer challenging and rewarding careers in designing (Successful Career and Immediate Employment).

S Exams, Discussions

N= None S= Supportive H = Highly Related

11.7 SYLLABUS

UNIT - IPN JUNCTION DIODE: Operation of PN junction Diode: No bias, forward bias and reverse bias, diode current equation (qualitative treatment), volt-ampere (V-I) characteristics, temperature dependence of V-I characteristics, ideal versus practical diode, static and dynamic resistances, diode equivalent circuits, breakdown mechanisms in semiconductor diodes, zener diode characteristics.UNIT - IIRECTIFIERS AND FILTERS: PN junction as a rectifier, half wave rectifier, Center-Tapped full wave rectifier, Bridge full wave Rectifier, Harmonic components in a rectifier circuit, Capacitor filter and Inductor filter.UNIT - IIIBIPOLAR JUNCTION TRANSISTOR (BJT): BJT construction, operation, symbol, transistor current components, input &output characteristics of a transistor in CB, CE and CC configurationsTRANSISTOR BIASING AND STABILIZATION: Need for biasing, operating point, DC and AC load lines, stability factor, fixed bias circuit, collector to base bias circuit, self bias circuit.UNIT - IVBJT AMPLIFIERS: Operation of CE amplifier, Operation of RC coupled amplifier, Operation of Class-A power amplifier, Operation of Class-B Push-Pull power amplifier

MLR Institute of Technology, Dundigal, Hyd-500043 Page 38

Page 39: 9.12TUTORIALQUESTIONS - MLR Institute of Web viewDepartment of CSE. Department of CSE. MLR Institute of Technology, Dundigal, Hyd-500043Page 2. MLR Institute of Technology, Dundigal,

Department of CSE

FIELD EFFECT TRANSISTOR: Junction field effect transistor (construction, principle of operation, symbol), volt-ampere characteristics of JFET, MOSFETS (construction, principle of operation, symbol), volt- ampere characteristics of MOSFETS in enhancement and depletion modes.UNIT - VFEEDBACK AMPLIFIERS: Feedback concepts, types of feedback circuits (block diagram representation), general characteristics of negative feedback amplifierOSCILLATORS: Barkhausen criterion, RC Phase shift oscillator using BJT, General form of LC oscillators, Hartley oscillator, Colpitts oscillator and Crystal oscillator.

TEXT BOOKS:1. J. Millman, Christos C. Halkias (2008), Electronic Devices and Circuits, Tata McGraw

Hill, New Delhi.2. R.L. Boylestad and Louis Nashelsky (2006), Electronic Devices and Circuits, 9th

edition, Prentice Hall of India, New Delhi.

REFERENCE BOOKS:1. Rober T. Paynter (2003), Introduction to Electronic Devices and Circuits, 6th edition,

Pearson Education, New Delhi, India.2. S. Salivahana, N. Suresh Kumar, A. Vallavaraj (2008), Electronic Devices and Circuits,

2nd edition, Tata McGraw Hill, New Delhi.

11.8 COURSE PLAN: The course plan is meant as a guideline. There may probably be changes.

LectureNo.

LearningObjective Unit Course Learning

Outcomes Topics to be covered Reference

1-3 1

I

To understand the physics of p-n junction

SEMICONDUCTOR DIODE CHARACTERISITCS:Qualitative theory of the p-n Junction

T1,R2

4-6 2To understand the characteristics of p-n junction and its temperature effects

The volt ampere characteristics, the temperature dependence of V-I characteristics

T1,R2

6-9 3To study the resistance offered by diode and study the equivalent diode models.

Diode resistance, ideal versus practical diodes, diode equivalent circuits,

T1,R2

10-11 4 To understand the concept of breakdown in diodes and

Breakdown mechanism in diode T2,R7

12-14 5 To study the operation and characteristics of Zener diode

Zener diode, V-I characteristics of Zener diode T2,R7

15-19 7

II

To understand how the diode acts as rectifier and study the characteristics of rectifiers

Half-wave rectification, Full-wave rectification T2

20-21 8

To understand the general conditions for filters andTo study the various filters used in power supplies to suppress ripple content.

General filter considerationsInductive, Capacitive, LC and CLC filters

T2

23-25 10 III To understand the basics of transistors

BIPOLAR JUNCTION TRANSISTORS:Introduction, transistor construction, transistor operation

T2

MLR Institute of Technology, Dundigal, Hyd-500043 Page 39

Page 40: 9.12TUTORIALQUESTIONS - MLR Institute of Web viewDepartment of CSE. Department of CSE. MLR Institute of Technology, Dundigal, Hyd-500043Page 2. MLR Institute of Technology, Dundigal,

Department of CSE

26-27 11 To understand the current components in transistor

Transistor current components, Transistor as an amplifier T2

28 12 To study the characteristics of CB,CE,CC configuration CB,CE,CC configurations T2

29 13 To understand the specifications of transistor

Limits of operation, transistor specifications T2

30 14 To understand the purpose of biasing

BJT BIASING:Need for biasing, operating point, load line analysis

T3

31 15 To study the bias stabilization techniques

Bias stabilization techniques: fixed bias T3

32 16 To study the bias stabilization techniques Collector to base bias T3

33 17 To study the bias stabilization techniques Self-bias T3

34 18To study the bias stabilization techniques and its variation effects

Stabilization against variations in Ico, VBE and b for the self bias circuit

T3

35 19 To study the bias compensation techniques Bias compensation techniques T3

36-37 20 To study the concept of thermal runaway and thermal stability

Thermal runaway and thermal stability T3

38 21

IV

BJT Amplifiers: introduction to understand the need for BJT amplifiers T3

39 22 Operation of CE Amplifier to understand theOperation of CE amplifier T3

40 23Operation of RC coupled amplifier

able to understand theOperation of RC coupled amplifier to use this concept in the design of audio amplifiers

T3

41 24Operation of Class A power amplifier

to understand the Operation of Class A power amplifier. to use this concept in the design of audio amplifiers.

T3

42 25 Operation of Class B Push-Pull power amplifier

to understand the Operation of Class B Push-Pull power amplifier to solve GATE Level problems on power amplifiers.

T3

42-45 26 To study the working principle and characteristics of JFET

FIELD EFFECT TRANSISTORS:Junction Field Effect Transistor (JFET) - principle of operation, volt ampere characteristics, advantages of JFET over BJT

T1,R T2

46-47 27 To study the working principle and characteristics of MOSFET

Introduction to MOSFETs - depletion and enhancement type MOSFETs, operation and volt-ampere characteristics.

T1

47-50 28 To study the biasing techniques of JFET

FET BIASING: Biasing techniques: fixed bias, source self-bias, voltage divider bias.

T1

52-53 29 V Feedback Amplifiers: Feedback concepts,types of feedback circuits (block diagram

able to understand about Feedback circuits.able to analyze how feedback

T1,R2

MLR Institute of Technology, Dundigal, Hyd-500043 Page 40

Page 41: 9.12TUTORIALQUESTIONS - MLR Institute of Web viewDepartment of CSE. Department of CSE. MLR Institute of Technology, Dundigal, Hyd-500043Page 2. MLR Institute of Technology, Dundigal,

Department of CSE

representation) is helpful for amplifiers. to understand the types of feedback circuits.

54 30general characteristics of negative feedback amplifier

able to understand the characteristics of negative feedback amplifier

T2

55-56 31OSCILLATORS: IntroductionBarkhausen criterion

able to understand about different types of oscillators. to understand about Barkhausen criterion.

T1,R2

57-58 32

RC Phase shift oscillator using BJT, General form of LC oscillators

able to understand how to build RC Phase shift oscillatorusing BJT

T2

59-61 33

Colpitts oscillator, Hartley oscillator ,Crystal oscillator

able to understand the operation of Hartley oscillator, Crystal oscillator, Colpitts oscillator

T1,R2

11.9 MAPPING COURSE OBJECTIVES LEADING TO THE ACHIEVEMENT OF PROGRAM OUTCOMES

CourseObjectives

Program Outcomes

A B C D E F G H I J K L M

I II III IV V

S= Supportive H = Highly Related

11.10 MAPPING COURSE OUTCOMES LEADING TO THE ACHIEVEMENT OF PROGRAM OUTCOMES:

CourseOutcomes

Program OutcomesA B C D E F G H I J K L M

1

2

3

4

5

S= Supportive H = Highly Related

11.11 OBJECTIVE QUESTIONS:

MLR Institute of Technology, Dundigal, Hyd-500043 Page 41

Page 42: 9.12TUTORIALQUESTIONS - MLR Institute of Web viewDepartment of CSE. Department of CSE. MLR Institute of Technology, Dundigal, Hyd-500043Page 2. MLR Institute of Technology, Dundigal,

Department of CSE

UNIT-I1. A Zener diode works on the principle of

A. Tunneling of charge carriers across the junctionB. Thermionic emissionC. Diffusion of charge carriers across the junctionD. Doping of charge carriers across the junctionAnswer A

2. In Gunn diodes electrons are transferred fromA. High to low mobility energy bands B. Low to high mobility energy bandsC. Valley to domain formationD. Domain to valley formationAnswer B

3. Schottky diodes, also called hot carrier diode, are used in wave shaping circuit becauseA. They have a small recovery timeB. They have a large reverse resistanceC. They have large forward currentD. Their peak inverse voltage is smallAnswer A

4. Silicon diode is less suited for low voltage rectifier operation because A. It can withstand high temperaturesB. Its reverse saturation current is lowC. Its cut-in voltage is highD. Its breakdown coltage is highAnswer D

5. Silicon is not suitable for fabrication of light emtting diodes because it isA. An indirect band gap semiconductorB. A direct band gap semiconductorC. A wide band gap semiconductorD. A marrow band gap semiconductorAnswer B

6. A general purpose diode is more likely to suffer avalanche breakdown than Zener breakdown becauseA. It is lightly dopedB. It’s leakage current is smallC. It has weak covalent bondsD. It has low reverse resistanceAnswer A

7. A Zener diodeA. Has a high forward voltage ratingB. Has a sharp breakdown at low reverse voltageC. Is useful as an AmplifierD. Has a negative resistanceAnswer B

8. Avalanche breakdown in a semiconductor diode occurs whenA. Reverse bias exceeds a certain valueB. Forward bias exceeds a certain valueC. Forward current exceeds a certain value

MLR Institute of Technology, Dundigal, Hyd-500043 Page 42

Page 43: 9.12TUTORIALQUESTIONS - MLR Institute of Web viewDepartment of CSE. Department of CSE. MLR Institute of Technology, Dundigal, Hyd-500043Page 2. MLR Institute of Technology, Dundigal,

Department of CSE

D. The potential barrier is reduced to zeroAnswer A

9. Zener breakdown results fromA. Strong electric fieldB. High applied potentialC. Any other causeAnswer A

10. The important advantage of tunnel diode is A. It is less sensitive to nuclear radiationB. It is less noisyC. It can be operated safely at high temperaturesD. NoneAnswer B

11. The temperature coefficient of a breakdown diode based on Avalanche breakdown isA. PositiveB. NegativeC. ZeroD. NoneAnswer A

12. Which of these is the best description of a Zener diodeA. It operates in the reverse regionB. It is a constant voltage deviceC. It is a constant current deviceD. It works in forward regionAnswer B

13. When two Zener diodes of each 10V and 15V are connected in series aiding, the overall voltage between them when they are in conduction isA. 10.6vB. 15.6vC. 25vD. ZeroAnswer C

14. In a standard regulator circuit using Zener diode 10v the input voltage varies from 25 to 40v and load current is 10mA to 20mA, the minimum Zener current is 5mA, the value of the series resistance in ohmsA. 1500B. 1200C. 600D. 1000Answer C

15. The LED’s are usually made of materials likeA. Ga and AsB. C and SiC. Ge and AsD. P ans SiAnswer A

16. Varactor diodes are used in FM receivers to obtainA. Automatic frequency controlB. Automatic gain control

MLR Institute of Technology, Dundigal, Hyd-500043 Page 43

Page 44: 9.12TUTORIALQUESTIONS - MLR Institute of Web viewDepartment of CSE. Department of CSE. MLR Institute of Technology, Dundigal, Hyd-500043Page 2. MLR Institute of Technology, Dundigal,

Department of CSE

C. Automatic volume control A. Automatic noise controlAnswer A

17. No load voltage of power supple is 100v and full load voltage is 80v, the percentage regulation isA. 0B. 25C. 20D. 2.5Answer B

18. Both Avalanche and Zener breakdown are commonly known asA. Zener breakdownB. Avalanche breakdownC. Current breakdownAnswer A

19. Zener diodes are used asA. Reference voltage elementsB. Reference current elementsC. Reference resistanceAnswer A

20. Zener diodes areA. Specially doped P-N junctionB. Normally doped P-N junctionC. Lightly doped P-N junctionAnswer A

UNIT-II1. D.C voltage in half-wave rectifier is less than that of full wave rectifier-yes/no2. A.C. Voltage in half-wave rectifier is less than that of full wave rectifier-yes/no3. The ripple factor in half wave rectifier with ideal diode is _____________1.214. The ripple factor in full wave rectifier with ideal diode is _____________0.485. The peak inverse voltage across the diode in half wave rectifier is_______vm6. The peak inverse voltage across the diode in full wave rectifier is_______2vm7. The peak inverse voltage across each diode in bridge rectifier is _________vm8. The rectification efficiency of full wave circuit with ideal diodes is______80.1%9. If vm =24v in full wave rectifier, vrms is______16.97v10. If vm =24v in half wave rectifier, vdc=________7.64v11. If vm=12v in full wave rectifier, vdc=_________7.64v12. No load means rl=0ohms-yes/no13. No load means rl=infinityohms –yes/no14. Full load means il=0-yes/no15. Full load means il is highest –yes/no16. The preferred rectifier is _________bridge rectifer17. The advantage of bridge rectifier over a full wave rectifier is ___________piv is vm18. The main disadvantage of full wave rectifier over bridge rectifier is _____piv is 2vm19. In full wave rectifier with pi section filter,vdc=______vm20. If c1 and c2 are high in pi section filter ,ripple factor is also high _________yes/no

UNIT-III

MLR Institute of Technology, Dundigal, Hyd-500043 Page 44

Page 45: 9.12TUTORIALQUESTIONS - MLR Institute of Web viewDepartment of CSE. Department of CSE. MLR Institute of Technology, Dundigal, Hyd-500043Page 2. MLR Institute of Technology, Dundigal,

Department of CSE

1. How much is the base-to-emitter voltage of a transistor in the "on" state?A. 0 VB. 0.7 VC.C. 0.7 mVD. Undefined

2. For what kind of amplifications can the active region of the common-emitter configuration be used?A. Voltage B. Current C. PowerD. All of the above

3. In the active region, while the collector-base junction is ________-biased, the base-emitter is ________-biased.A. forward, forward B. forward, reverseC. reverse, forwardD. reverse, reverse

4. What range of resistor values would you get when checking a transistor for forward- and reverse-biased conditions by an ohmmeter?A. 100 to a few k , exceeding 100 kB. Exceeding 100 k , 100 to a few kC. Exceeding 100 k , exceeding 100 kD. 100 to a few k , 100 to a few k

5. Calculate minority current ICO if IC = 20.002 mA and IC majority = 20 mA.A. 20 AB. 0.002 AC. 2 nAD. 2 A

6. In which region are both the collector-base and base-emitter junctions forward-biased?A. ActiveB. CutoffC. SaturationD. All of the above

7. What does a reading of a large or small resistance in forward- and reverse-biased conditions indicate when checking a transistor using an ohmmeter?A. Faulty deviceB. Good deviceC. Bad ohmmeterD. None of the above

8. Determine the value of when = 100.A. 1.01B. 101C. 0.99D. Cannot be solved with the information provided

9. Which of the following can be obtained from the last scale factor of a curve tracer?A. hFE

B. dc

C. ac

MLR Institute of Technology, Dundigal, Hyd-500043 Page 45

Page 46: 9.12TUTORIALQUESTIONS - MLR Institute of Web viewDepartment of CSE. Department of CSE. MLR Institute of Technology, Dundigal, Hyd-500043Page 2. MLR Institute of Technology, Dundigal,

Department of CSE

D. ac

10. dc = ________A. IB / IE

B. IC / IE

C. IC / IB

D. None of the above11. What are the ranges of the ac input and output resistance for a common-base

configuration?A. 10 –100 , 50 k –1 MB. 50 k –1 M , 10 –100 C. 10 –100 k , 50 –1 kD. None of the above

12. What is the most frequently encountered transistor configuration?A. Common-baseB. Common-collectorC. Common-emitterD. Emitter-collector

13. Which of the following regions is (are) part of the output characteristics of a transistor?A. ActiveB. CutoffC. SaturationD. All of the above

14. For a properly biased pnp transistor, let IC = 10 mA and IE = 10.2 mA. What is the level of IB?A. 0.2 AB. 200 mAC. 200 AD. mA

15. Which component of the collector current IC is called the leakage current?A. MajorityB. IndependentC. MinorityD. None of the above

16. What is the ratio of the total width to that of the center layer for a transistor?A. 1:15B. 1:150C. 15:1D. 150:1

17. dc for this set of collector characteristics is within ________ percent of ac.

A. 2

MLR Institute of Technology, Dundigal, Hyd-500043 Page 46

Page 47: 9.12TUTORIALQUESTIONS - MLR Institute of Web viewDepartment of CSE. Department of CSE. MLR Institute of Technology, Dundigal, Hyd-500043Page 2. MLR Institute of Technology, Dundigal,

Department of CSE

B. 5C. 7D. 10

18. Calculate dc at VCE = 15 V and IB = 30 A.

A. 100B. 116C. 50D. 110

19. Calculate ac for IC = 15 mA and VCE = 5 V.

A. 200B. 180C. 220D. None of the above

20. Use this table of collector characteristics to calculate ac at VCE = 15 V and IB = 30 A.

MLR Institute of Technology, Dundigal, Hyd-500043 Page 47

Page 48: 9.12TUTORIALQUESTIONS - MLR Institute of Web viewDepartment of CSE. Department of CSE. MLR Institute of Technology, Dundigal, Hyd-500043Page 2. MLR Institute of Technology, Dundigal,

Department of CSE

A. 100B. 106C. 50D. 400

UNIT-IV1. Calculate VCE.

A. –4.52 VB. VC. –9 VD. 9 V

2. For the BJT to operate in the active (linear) region, the base-emitter junction must be ________-biased and the base-collector junction must be ________-biased.A. forward, forwardB. forward, reverseC. reverse, reverseD. reverse, forward

3. Determine the reading on the meter when VCC = 20 V, RC = 5 k , and IC = 2 mA

MLR Institute of Technology, Dundigal, Hyd-500043 Page 48

Page 49: 9.12TUTORIALQUESTIONS - MLR Institute of Web viewDepartment of CSE. Department of CSE. MLR Institute of Technology, Dundigal, Hyd-500043Page 2. MLR Institute of Technology, Dundigal,

Department of CSE

A. 10 VB. –10 VC. 0.7 VD. 20 V

4. In a fixed-bias circuit, which one of the stability factors overrides the other factors?A. S(ICO)B. S(VBE)C. S( )D. Undefined

5. Calculate the voltage across the 91 k resistor.

A. 18 VB. 9.22 VVC. None of the above

1. Calculate the value of VCEQ.

A. 8.78 VB. 0 VC. V

2. For what value of does the transistor enter the saturation region?

MLR Institute of Technology, Dundigal, Hyd-500043 Page 49

Page 50: 9.12TUTORIALQUESTIONS - MLR Institute of Web viewDepartment of CSE. Department of CSE. MLR Institute of Technology, Dundigal, Hyd-500043Page 2. MLR Institute of Technology, Dundigal,

Department of CSE

A. 20B. 50C. 75D. 116

3. Which of the following is (are) related to an emitter-follower configuration?A. The input and output signals are in phase.B. The voltage gain is slightly less than 1.C. Output is drawn from the emitter terminal.D. All of the above

4. At what region of operation is the base-emitter junction forward biased and the base-collector junction reverse biased?A. SaturationB. Linear or activeC. CutoffD. None of the above

5. For an "on" transistor, the voltage VBE should be in the neighborhood of 0.7 VA. TrueB. False

6. Calculate ICsat.

A. 35.29 mAB. mAC. mAD. mA

7. Determine ICQ at a temperature of 175º C if ICQ = 2 mA at 25º C for RB / RE = 20 due to the S( ) stability factor.

MLR Institute of Technology, Dundigal, Hyd-500043 Page 50

Page 51: 9.12TUTORIALQUESTIONS - MLR Institute of Web viewDepartment of CSE. Department of CSE. MLR Institute of Technology, Dundigal, Hyd-500043Page 2. MLR Institute of Technology, Dundigal,

Department of CSE

A. 2.417 mAB. 2.392 mAC. 2.25 mAD. 2.58 mA

13. Which of the following currents is nearly equal to each other?A. IB and ICB. IE and ICC. IB and IED. IB, IC, and IE

14. Which of the following voltages must have a negative level (value) in any npn bias circuit?A. VBEB. VCEC. VBCD. None of the above

15. Determine the values of VCB and IB for this circuit.

A. 1.4 V, 59.7 AB. –1.4 V, 59.7 AC. –9.3 V, 3.58 AD. 9.3 V, 3.58 A

16 For the typical transistor amplifier in the active region, VCE is usually about ________ % to ________ % of VCC.A. 10, 60B. 25, 75C. 40, 90

17. The total time required for the transistor to switch from the "off" to the "on" state is designated as ton and defined as the delay time plus the time element.A. TrueB. False

18. Calculate Rsat if VCE = 0.3 V.

MLR Institute of Technology, Dundigal, Hyd-500043 Page 51

Page 52: 9.12TUTORIALQUESTIONS - MLR Institute of Web viewDepartment of CSE. Department of CSE. MLR Institute of Technology, Dundigal, Hyd-500043Page 2. MLR Institute of Technology, Dundigal,

Department of CSE

A. 49.2 B. 49.2 kC. 49.2 mD. 49.2 M

19. The ratio of which two currents is represented by ?A. IC and IE

B. IC and IB

C. IE and IB

D. None of the above20. It is desirable to design a bias circuit that is independent of the transistor beta.

A. TrueB. False0

UNIT-V1 For an n-channel JFET having drain-source voltage constant if the gatesource

voltage is increased(more negative) pinch-off would occur for:A. High value of drain currentB. saturation value of drain currentC. Zero drain currentD. gate current equal to drain currentAnswer A

2 For a UJT, if R1=resistance from emitter to the base 1,R2 = resistance from emitter to the base 2 and RBB=(R1+R2), then the instrinsic stand-off ratio is :A. R1/R2 B. R1/RBBC. R2/R1D. R2/RBBAnswer A

3 For a junction Fet it the pinch off region as the drain voltage is increased, the drain current:A. Becomes Zero B. abruptly decreasesC. abruptly increases D. remains constant

MLR Institute of Technology, Dundigal, Hyd-500043 Page 52

Page 53: 9.12TUTORIALQUESTIONS - MLR Institute of Web viewDepartment of CSE. Department of CSE. MLR Institute of Technology, Dundigal, Hyd-500043Page 2. MLR Institute of Technology, Dundigal,

Department of CSE

Answer A4 In modern MOSOFETs, the material used for the gate is:

A. high purity silicon B. high purity silicaC. heavily doped polycrystalline siliconD. epitaxially grown siliconAnswer C

5 the threshold voltage of an n-channel MOSFET can be increased by:A. increasing the channel dopant concentrationB. reducing the channel dopant concentrationC. reducing the gate oxide thicknessD. reducing the channel lengthAnswer B

6 An infrared LED is usually fabricated from:A. Ge B. Si C. Ga, As D. Ga,As,PAnswerC

7 An n-channel JFET has a pinch – off voltage of VP=-5V,Vds(max)=20V and gm=2mA/V. the minimum ‘ON’ resistance is achieved in r’th JFET for,A. VGS=-7V and VDS=0VB. VGS=0V and VDS=0V C. VGS=0V and VDS=20VD. VFGS=-7V and VDS= 20VAnswer B

8 The JFET in the given current has an Idss=10mA and VP=5V. the value of the resistance Rs for a drain current Id= 6.4mA is :A. 150ohms B. 470 ohms C. 560 ohms D. 1 Kilo-ohms

9 List 1 List2A. voltage controlled device 1) Bipolar Junction transistorB. current controlled device 2)Unijunction transistorC. Conductance modulation device 3)Field effect transistor D. Negative conductance device 4)IMPATT diodeAnswer A=3,B=1,C=4,D=2

10 In a JFET, trans conductance gm is of the order of A. 1mS B. 100mS C. 1S D. 100SAnswer A

11 in a FET, dynamic drain resistance rd is the order of A. 1K ohms B. 10K ohms C. 100 ohms D. 100K ohms Answer C

MLR Institute of Technology, Dundigal, Hyd-500043 Page 53

Page 54: 9.12TUTORIALQUESTIONS - MLR Institute of Web viewDepartment of CSE. Department of CSE. MLR Institute of Technology, Dundigal, Hyd-500043Page 2. MLR Institute of Technology, Dundigal,

Department of CSE

12 in a MOSFET, dynamic drain resistance rd is of the order of A. 10K ohms B. 1k ohms C. 10 ohms D. 100k ohmsAnswer A

13 The input resistance rgs in small signal model of MOSFET is of the order of A. 100K ohms B. 1M ohms C. 100M ohms D. 10000M ohmsAnswer D

14 the feedback resistance rgd in small signal model of MOSFET is of the order of A. 1M ohms B. 100M ohms C. 10000M ohms D. 1000000M ohmsAnswer D

15 The feedback capacitance Cgd in small signal high frequency model of JFET is of the order of A. 5pF B. 5-pF C. 500pF D. 1pFAnswer A

16 The drain to source resistance Cds in high frequency model of a JFET is of the order of A. 1pF B. 10pF C. 100pF D. 1000pFAnswer A

17 the gate to source capacitance Cgs in small signal high frequency model of a JFET of the order of A. 5pF B. 50pF C. 500pF D. 5000pFAnswer A

18 In an FET , trasconductance gm is proportional toA. Ids B. sqre of I DS C. sqre root I DC D. 1/I DCAnswer C

19 In an FET, gm0 is proportional to:A. I dss B. sqre root I dss C. sqre of I dss D. 1/I dss

MLR Institute of Technology, Dundigal, Hyd-500043 Page 54

Page 55: 9.12TUTORIALQUESTIONS - MLR Institute of Web viewDepartment of CSE. Department of CSE. MLR Institute of Technology, Dundigal, Hyd-500043Page 2. MLR Institute of Technology, Dundigal,

Department of CSE

20 An infrared LED is usually fabricated from:A. Ge B. Si C. Ga, As D. Ga,As,P

11.12 TUTORIAL QUESTION BANK (5/UNIT) PART – A (SHORT ANSWER QUESTIONS)

S. No QuestionBlooms

TaxonomyLevel

CourseOutcome

UNIT-I

1 Define the term reverse recovery time of a diode Level2 A

2 Mention the type of two capacitive effects that could occur in a practical diode Level2 A

3 Draw the symbol of an ideal diode and its corresponding v-i characteristics Level3 A

4 What is the net flow of charge in a semiconductor diode when zero potential is applied across it Level3 A

5 What did you understand with space charge in a diode Level2 A

6 What is the significance of dynamic resistance in diode? Explain how it can be computed? Level2 A

UNIT-II

1 What did you understand by peak inverse voltage (PIV) rating of a diode Level2 C

2 What is the essentiality and significance of series and parallel configuration of diodes Level3 D

3 If the line frequency is 60 Hz, what is the output frequency of a half-wave rectifier Level2 C

4 A diode is in series with 220 ohm, if the voltage across the resistor is 4 V. What is the current through the diode? Assume ideal diode Level3 D

5 If the output filter capacitance is increased, what happens to the ripple content of output voltage? Level3 D

6 The diodes in a bridge rectifier each have a maximum DC current rating of 2 A. What is the maximum value of a load current? Level3 D

UNIT-III

1 In a cutoff region of output characteristics of a common-base transistor, which junctions are reverse biased. Level1 E

2 Draw and explain the common emitter configuration of BJT Level2 E

3 What are Alpha (α) and Beta (β) in transistor terminology? Level3 E

MLR Institute of Technology, Dundigal, Hyd-500043 Page 55

Page 56: 9.12TUTORIALQUESTIONS - MLR Institute of Web viewDepartment of CSE. Department of CSE. MLR Institute of Technology, Dundigal, Hyd-500043Page 2. MLR Institute of Technology, Dundigal,

Department of CSE

4 A transistor has a current gain of 175. If the base current is 0.1 mA, what is the collector current? Level1 E

5 What is the most commonly used transistor biasing configuration? Why? Level1 E

UNIT-IV

1 For linear amplification of BJT, the DC operating point should not be too close to the maximum power and voltage rating why? Level2 F

2 Why the fixed bias configuration of transistor biasing arrangements is unstable? Level2 F

3Design a voltage divider bias network using a supply of 24 V, a transistor with a beta of 110, and an operating point of ICQ=4 mA and VCEQ=8V. Choose VE=1/8 VCC, Use standard values

Level2 F

4 What is the primary type of biasing used with discrete bipolar transistor circuits? Level2 F

5 Write down important features with respect to stabilization of BJT against variations in ICO, VBE and β Level2 F

UNIT-V

1 Mention the advantages of JFET over BJT Level1 H

2 An E-MOSFET has ID(active) = 1 mA and VDS(active)=10 V. What does its drain resistance equal in the active region Level2 H

3 Write down the expression of drain current ID of JFET in terms of VGS Level2 H

4 What is the significant difference between the construction of an enhancement-type and depletion type MOSFETs Level3 H

5 In general compare, JFET self-bias and JFET common gate bias Level4 H

PART – B (LONGANSWER QUESTIONS)

S. No QuestionBlooms

TaxonomyLevel

CourseO

utcome

UNIT-I

1 Describe in your own words the conditions established by forward and reverse bias conditions on a p-n junction diode and how the resulting current is affected Level1 B

2 \With a relevant graph, explain the forward and reverse characteristics of a practical diode Level2 B

3 Mention the differences between an ordinary diode and a zener diode Level4 B

4 What did you understand by break-down region in diode, explain in detail Level2 B

5 From the basics of an electronic charge, derive an expression of a diffusion capacitance of a diode Level5 A

UNIT-II

MLR Institute of Technology, Dundigal, Hyd-500043 Page 56

Page 57: 9.12TUTORIALQUESTIONS - MLR Institute of Web viewDepartment of CSE. Department of CSE. MLR Institute of Technology, Dundigal, Hyd-500043Page 2. MLR Institute of Technology, Dundigal,

Department of CSE

1. Discuss in detail about the load-line analysis of a diode Level1 C

2. Draw the full-wave rectification diagram feeding R-load and draw output voltage waveform Level4 C

3. Discuss, how zener diode can act as a voltage regulator? Level3 D

4. Discuss about the various filters, which can be employed in most of the power applications Level3 C

5. A HWR circuit has a 25v(rms) sinusoidal are input and a 600Ω load resistance . caluculate the peak output voltage ,peak load current when Vf =0.7u Level3 D

UNIT-III

1.Discuss in detail about the load-line analysis of a diode Level1 C

2.Draw the full-wave rectification diagram feeding R-load and draw output voltage waveform Level6 C

3.Discuss, how zener diode can act as a voltage regulator? Level4 D

4.Discuss about the various filters, which can be employed in most of the power applications Level3 C

5.A HWR circuit has a 25v(rms) sinusoidal are input and a 600Ω load resistance . caluculate the peak output voltage ,peak load current when Vf =0.7u Level3 D

UNIT-IV

1. Explain in brief, how Q-point is determined from the device characteristics? Level1 G

2. Write down the base current expression of BJT, when emitter is stabilized Level1 G

3.Draw a voltage divider bias (VDB) circuit. Write down the procedure for calculating the collector emitter voltage. Why does this circuit have a very stable Q point?

Level1 G

4. Describe different kinds of biasing BJT? Level2 G

5. Discuss in brief about thermal runaway and thermal stability with respect to BJT biasing Level2 H

UNIT-V

1 Determine the value of ID is the given circuit if IDSS-3mA, Vass(off)=-6v and Vus=-3v of JFET. Level2 H

2 A JFET self bias has VDD=30v, RD=4.7kΩ, RS=820Ω, and RG=1mΩ. Calculate the min value of VDS. Level2 H

3 Explain the operation of depletion mode and current mode of JFET Level2 H

4 Explain the principle of MOSFET is depletion with neat sketches and output characteristics. Level2 H

5The drain current ID of an FET changes from 8mA to 4mA for a change of VGS from -1V to -1.5V keeping the VDS constant. If the AC resistance in the drain circuit is 200KΩ. Calculate values ofamplification factor of the JFET

Level1 H

MLR Institute of Technology, Dundigal, Hyd-500043 Page 57

Page 58: 9.12TUTORIALQUESTIONS - MLR Institute of Web viewDepartment of CSE. Department of CSE. MLR Institute of Technology, Dundigal, Hyd-500043Page 2. MLR Institute of Technology, Dundigal,

Department of CSE

11.13 ASSIGNMENT QUESTIONS:

S. No QuestionBlooms

TaxonomyLevel

CourseOutcome

UNIT-I

1 Explain about the transition capacitance Ct of a p-n junction diode. Derive the expression for the same. Level2 A

2 Derive the expression for the diffusion capacitance Cd of a p-n junction diode. Level3 J

3 In the case of a forward biased p-n junction sketch the current components and explain about the same. Level3 A

4 Explain the concept of holes and term mobility. Level2 A

5 Explain about the tunneling phenomenon .explain how tunnel diode exhibits negative resistance characteristics. Level1 J

6Explain about zener breakdown mechanism .draw the V-I characteristics and explain the same .what are the applications of zener diode.

Level3 A

7 What are the characteristic features of varactor diode? Draw its symbol and explain about the applications of device. Level3 J

UNIT-II

1 Draw a circuit diagrams to show two methods of producing a negative output voltage from a half wave rectifies briefly explain. Level2 A

2

Draw the circuit diagram of a bridge rectifies to gather with its input waveforms. Explain the operation of the circuit by identifying the forward biased and reverse biased diodes during each half cycle of the input waveform.

Level3 D

3 For a rectifier circuit with capacitor filtering, explain ripple voltage and diode peak reverse voltage. Level3 D

4 Explain the function of a transformer in a dc power supply & discuss the factors involved in the specification of power supply transform. Level2 E

5 Explain the operation of full wave rectifier with neat sketches Level1 A

UNIT-III

1 With the help of bias voltages explain the function of pnp transistor. Level2 E

2 Explain the V-I characteristics of a common bias configuration circuit of a BJT. Level3 F

3 Plot the V-I characteristics of a common emitter configuration of BJT and identify the three regions of transistor in the plot. Level3 E

4 Explain briefly how a BJT can be used as a switch. Level2 G

5 Given βdc=180 and Ic=2.0mA, find IE and IB and Idc of BJT. Level1 E

MLR Institute of Technology, Dundigal, Hyd-500043 Page 58

Page 59: 9.12TUTORIALQUESTIONS - MLR Institute of Web viewDepartment of CSE. Department of CSE. MLR Institute of Technology, Dundigal, Hyd-500043Page 2. MLR Institute of Technology, Dundigal,

Department of CSE

6 Define carrier life time and base width modulation or early effect Level3 F

UNIT-IV

1 What are the factors affecting the stability factors of Q.point. Level2 G

2 Derive the expression for the stability of factor S of an BJT amplifier. Level3 F

3 Determine the stability factor of a basic circuit. Level3 F

4 Derive the stability factor of a self bias circuit. Level2 F

5 Derive an expression for collector current ICi n cB configuration Level1 G

UNIT-V

1 Compare JFET and BJT. Level4 H

2 With the help of a neat structure of a P-channel operation. Level5 H

3 Explain the operation of depletion mode and current mode of JFET Level3 H

4 Draw the transfer characteristics of a JFET and explain the same Level1 H

5 Explain the difference between Enhanced and Depletion mosfets Level3 H

MLR Institute of Technology, Dundigal, Hyd-500043 Page 59

Page 60: 9.12TUTORIALQUESTIONS - MLR Institute of Web viewDepartment of CSE. Department of CSE. MLR Institute of Technology, Dundigal, Hyd-500043Page 2. MLR Institute of Technology, Dundigal,

Department of CSE

12. DISCRETE MATHEMATICAL STRUCTURES (A10562)

12.0 COURSE DESCRIPTION

Course Title DMSCourse Code A10562Regulation R15-JNTUH

Course StructureLectures Tutorials Practical’s Credits

4 2 - 4Course Coordinator G. Kiran Kumar

Team of Instructors P. Amarendra Reddy ,V.Veerabhadram,T.Nirmala

12.1 COURSE OVERVIEW: Learn the fundamental concepts in mathematics. It can be used by the students in

computer science as an introduction to the underlying ideas of mathematics for computer science. It explains topics like mathematical logic, predicates, relations, functions, combinatorics, algebraic structures and graph theory.

12.2 PREREQUISITE(S):

Level Credits Periods / Week PrerequisitesUG 4 4 Fundamentals of Computer, Basic Mathematics

12.3 MARKS DISTRIBUTION:

Session Marks University EndExam Marks Total Marks

There shall be 2 midterm examinations. Each midterm Examination Consists of subjective type and Objective type tests.The subjective test is for 10 marks, with duration of 1 hour. Subjective test of each semester shall contain 4 questions; the student has to answer2 questions, each carrying 5 marks.The objective type test is for10 marks with duration of 20 minutes. It consists of 10 Multiple choice and 10 objective type questions, the student has to answer all the questions and each carries half mark.First midterm examination shall be conducted for the first four units of syllabus and second midterm examination shall be conducted for the Remaining portion.Five marks are marked for assignments. There shall be two assignments in every theory course. Marks shall be awarded considering the average of two assignments in each course

75 100

12.4 EVALUATION SCHEME:

S. No Component Duration Marks1 I Mid Examination 80minutes 20

2 I Assignment 5

3 II Mid Examination 80minutes 20

4 II Assignment 5

MLR Institute of Technology, Dundigal, Hyd-500043 Page 60

Page 61: 9.12TUTORIALQUESTIONS - MLR Institute of Web viewDepartment of CSE. Department of CSE. MLR Institute of Technology, Dundigal, Hyd-500043Page 2. MLR Institute of Technology, Dundigal,

Department of CSE

5 External Examination 3 hours 75

12.5 a) COURSE OBJECTIVES: I. Identify and distinguish between the notion of discrete and continuous mathematical

structuresII. Analyze the basic concepts of relations and functions

III. Learn the concepts groups and group homomorphismIV. Understand to solve problems using counting techniques and combinatory in the

context of discrete probabilityV. Apply principles of Recurrence Relations to calculate generating functions and solve

the Recurrence relations

b) COURSE OUTCOMES:a) Analyze and examine the validity of argument by using propositional and predicate

calculusb) Apply basic counting techniques to solve the combinatorial problemsc) Apply sets relations and di graphs to solve applied problemsd) Understand the basic concepts of graph theory and some related theoretical problemse) Students will participate in GATE, PGECET and other competitive examinations

12.6 HOW COURSE OUTCOMES ARE ASSESSED:

Program Outcomes Level ProficiencyAssessed by

A Ability to apply the knowledge of mathematics, Computing, Science and engineering to solve Computer Science and Engineering problems. S Assignments,

Exams

B Ability to design and conduct engineering experiments, as well as to analyze S Assignments,Tutorials

CAn ability to design and construct a hardware and software system, component, or process to meet desired needs, within realistic constraints.

Assignment, Tutorial, Lectures

D An ability to function on multi-disciplinary teams SLectures,Tutorials,

Problem solving

E An ability to identify, formulate, and solve engineering problems H Lectures

F An understanding of professional, social and ethical responsibility N --

G

An ability to communicate effectively. The broad education necessary to understand the H. impact of engineering solutions in a global, economic, environmental, and societal context

N Lectures, Motivation

I A recognition of the need for, and an ability to engage in life-long learning HAssignments,

Tutorials,Exams

J A knowledge of con temporary issues N --

K An ability to use the techniques, skills and modern engineering tools necessary for Engineering practice. N

--

L Graduates are able to participate and succeed in competitive examination like GRE, GATE, TOEFL, GMAT etc. H Tutorials

Assignments

M An ability to use the techniques, skills, and. modern engineering tools necessary for the development of engineering system H Lectures

MLR Institute of Technology, Dundigal, Hyd-500043 Page 61

Page 62: 9.12TUTORIALQUESTIONS - MLR Institute of Web viewDepartment of CSE. Department of CSE. MLR Institute of Technology, Dundigal, Hyd-500043Page 2. MLR Institute of Technology, Dundigal,

Department of CSE

N An ability to setup an enterprise. H Lectures

N= None S= Supportive H = Highly Related

12.7 SYLLABUS:

OBJECTIVES:To develop problem-solving techniques and explore topics in a variety of areas of

discrete mathematics, including but not limited to logic, graph theory, set theory, recursions, combinatorics, and algorithms. Students will learn to express statements in the language of formal logic and draw conclusions, model situations in terms of graph and set theory, find and interpret recursive definitions for mathematical sequences, use combinatorial methods to approach counting problems.

OUTCOMES:• Ability to Illustrate by examples the basic terminology of functions, relations, and sets

and demonstrate knowledge of their associated operations. • Ability to Demonstrate in practical applications the use of basic counting principles of

permutations, combinations, inclusion/exclusion principle and the pigeonhole methodology.

• Ability to represent and Apply Graph theory in solving computer science problems

UNIT – IMathematical Logic: Statements and notations, Connectives, Well formed formulas, Truth Tables, Tautology, Equivalence implication, Normal forms, Quantifiers, Universal quantifiers. Predicates: Predicative logic, Free & Bound variables, Rules of inference, Consistency, Proof of contradiction, Automatic Theorem Proving.UNIT - IIRelations: Properties of Binary Relations, Equivalence Relation, Transitive closure, Compatibility and Partial ordering relations, Lattices, Hasse diagram. Functions: inverse Function , Composition of functions, Recursive Functions.UNIT - IIIElementary Combinatory: Basis of counting, Combinations & Permutations, With repetitions, Constrained repetitions, Binomial Coefficients, Binomial Multinomial theorems, The principles of Inclusion – Exclusion, Pigeon- hole principles and its applications.UNIT - IVRecurrence Relation: Generating Functions, Function of Sequences, Calculating Coefficient of generating function, Recurrence relations, Solving recurrence relation by substitution and Generating functions , Characteristics roots solution, In homogeneous Recurrence Relation.UNIT - VIntroduction to Trees, Spanning rees, DFS, BFS, Minimal Spanning, Trees, Prims, Kruskal‘sAlgorithm, Representation of Graphs, Planar Graphs, Graph theory and applications. Isomorphism and sub graphs, Multi graph and Euler circuits, Hamiltonian Graphs, Chromatic number.

TEXT BOOKS:1. Discrete Mathematics with Applications to Computer Science, J P Trembley and R

Manohar, TMH, 2008. (Units I and II)

MLR Institute of Technology, Dundigal, Hyd-500043 Page 62

Page 63: 9.12TUTORIALQUESTIONS - MLR Institute of Web viewDepartment of CSE. Department of CSE. MLR Institute of Technology, Dundigal, Hyd-500043Page 2. MLR Institute of Technology, Dundigal,

Department of CSE

2. Discrete Mathematics for Computer Scientists and Mathematicians, second edition, J.L.Mott, A. Kandel, T.P. Baker, PHI

REFERENCE BOOKS:1. Elements of Discrete Mathematics- A Computer Oriented Approach, C.L.Liu, D.P.

Mohapatra, 3rd edition, TMH. 2. Discrete and Combinatorial Mathematics- An Applied Introduction-5th Edition– Ralph.

P.Grimaldi, Pearson Education. 3. Discrete Mathematics with applications, Thomas Koshy, Elsevier. 4. Discrete Mathematical Structures, Mallik and Sen, Cengage Learning. 5. Discrete Mathematical Structures, BernandKolman, Robert C. Busby, Sharon Cutler

Ross, PHI. 6. Discrete Mathematics and its Applications, 6th edition, K.H.Rosen, TMH. 7. Discrete Mathematics, Lovasz, Springer. 8. Logic and Discrete Mathematics, Grass Man and Tremblay, Pearson Education. 9. Discrete Mathematics, S K Chakraborthy and B K Sarkar, Oxford, 2011.

12.8 COURSE PLAN:

Lecture No. Course Learning Outcomes Blooms level Topics to be covered Reference

L0

Discuss and apply the basic methods of discrete(non continuous) mathematics in Computer Science

Remember Statements and notations T1:1.1-1.5

L1 Explain and understand the use of various types of connectives Apply

Connectives http://nptel.ac.in/video.php?subjectId=106106094/1

T1:1.9-1.10

L2 Discuss about Well-formed formulas and Tautologies Remember

Well formed formulas http://nptel.ac.in/video.php?subjectId=106106094/1

T1:1.4,1.6-1.8,2.1-2.3

L3 Describe Statement Formulas and construct Truth Tables Remember

Truth Tables http://nptel.ac.in/video.php?subjectId=106106094/1

T1:2.5,2.6

L4 Describe Statement Formulas and construct Truth Tables Remember Tautology

http://nptel.ac.in/video.php?subjectI T1:2.8

L5-L6 Understand the Equivalence of Formulas Understand

Equivalence implication Normal forms http://nptel.ac.in/courses 106106094/8 T1:3.1

L7Apply equivalent formulas and reduce into Disjunctive Normal Forms(DNF)

Apply CNF, DNF http://nptel.ac.in/video. php? Subject I d=106106094/8 T1:5.1-5.2

L8Apply equivalent formulas and reduce into Principle Disjunctive Normal Forms(PDNF)

ApplyPCNFhttp://nptel.ac.in/video.php?subjectI d=106106094/8 T1:5.3

L9Apply equivalent formulas and Principle Conjunctive Normal Forms(PCNF)

ApplyPDNFhttp://nptel.ac.in/video.php?subjectI d=106106094/8 T1:5.4

MLR Institute of Technology, Dundigal, Hyd-500043 Page 63

Page 64: 9.12TUTORIALQUESTIONS - MLR Institute of Web viewDepartment of CSE. Department of CSE. MLR Institute of Technology, Dundigal, Hyd-500043Page 2. MLR Institute of Technology, Dundigal,

Department of CSE

L10-L11 Explain and understand the use of quantifiers Apply

Quantifiers, universal quantifiershttp://nptel.ac.in/courses/106106094/3

T1:5.4

L12 Understand the importance and usage of predicates Apply

Predicates: Predicative logic,http://nptel.ac.in/courses/106106094/3 T1:6.1-6.2

L13 Define free and bound variables Free & Bound variables, T1:6.3-6.4

L14 Discover the methods of proving theorems by Rules of Inference Understand

Rules of inference,http://nptel.ac.in/video.php?subjectI d=106106094/5 T1:6.5-6.7

L15-l6Apply the knowledge of Consistency of Premises and Indirect Method of Proof

ApplyConsistency ,proof of contradictionhttp://nptel.ac.in/courses/106106094/7

T1:8.1-8.3

L17 Solve the problems by using Automatic Theorem Proving Apply Automatic Theorem Proving

T1:9.1-9.2

L18Understand and analyze the Properties of Binary Relations in a Set

Understand

Relations :Properties of Binary Relations, http://nptel.ac.in/courses/106106094/13

T1:9.5-9.6

L19-L20Apply the knowledge of Equivalence Relations in problem solving

ApplyEquivalence and, transitive closure,http://nptel.ac.in/courses/106106094/23 T1:10.1-10.3

L21 Apply the knowledge of compatibility Apply

Compatibility and partial ordering elations,http://nptel.ac.in/courses/106106094/22

T1:11.1-11.2

L22 Apply the knowledge of Lattices ApplyLattices, http://nptel.ac.in/courses/106106094/40 T1:11.3-11.4

L23 Apply the knowledge of Hasse diagram Apply Hasse diagram T1:11.5-11.6

L24-L25 Apply the knowledge of Functions Apply

Functions:InverseFunctionCompositionoffunctions,recursiveFunctions, http://nptel.ac.in/courses/106106094/23

T1:12.1

L26 Describe Lattices UnderstandLattice and its Properties,http://nptel.ac.in/courses/106106094/28

T1:12.4

L27-L29Describe and analyze the computational processes using Algebraic Structures

Understand

Algebraicstructures:Algebraicsystems,Examplesandgeneralproperties, http://nptel.ac.in/courses/106106094/28

T1:12.5-12.6

L30Explain and analyze the concepts of Semi groups and Monoids in algebraictructures

Apply Semi groups and monads,T1:7.5

L31-L32 Analyze the computational processes using Groups Analyze Groups sub groups’ homomorphism

Isomorphism. T1:7.6-7.7

MLR Institute of Technology, Dundigal, Hyd-500043 Page 64

Page 65: 9.12TUTORIALQUESTIONS - MLR Institute of Web viewDepartment of CSE. Department of CSE. MLR Institute of Technology, Dundigal, Hyd-500043Page 2. MLR Institute of Technology, Dundigal,

Department of CSE

L33Analyze the computational processes using analytic and combinatorial methods

Analyze Elementary Combinatorics: Basis of counting, T1:14.4-14.7

L34 Explain the concepts of elementary combinatorics. Apply

Combinations & Permutations, with repetitions,http://nptel.ac.in/courses/106106094/28 T1:14.8-14.9

L35 Explain the Principle of Inclusion-Exclusion Apply Combinations & Permutations,

With repetitions T2:15-15.9

L36 Explain the concepts of elementary combinatorics. Apply Constrained repetitions, T2:16.

L37Discuss the use of Binomial Coefficient Understand Binomial Coefficients, T2:16.8

L38Apply the principles of The Binomial and Multinomial Theorems

Apply Binomial Multinomial theorems, T1:17-17.2

L39-L41 Explain the Principle of Inclusion- Exclusion Apply

The principles of Inclusion– Exclusion. Pigeon hole principles http://nptel.ac.in/courses/106106094/27

T1:17.3-17.5

L42 Applications Applications T1:17.6-17.9

L43 l

Analyze and formulate to Solve Recurrence Reations by Substitution and Generating Functions

Analyze

Recurrence Relation: GeneratingFunctionshttp://nptel.ac.in/courses/106106094/28

T1:18-18.3

L44 Understand the methods of Characteristic Roots Understand Function of Sequences Calculating T1:18.3-18.5

L45-L46 Understand the methods of Characteristic Roots Understand Coefficient of generating unction,

Recurrence relations T2:18.6-18.9

L47-L48

Analyze and apply the methods to Solve substitution and Generating funds. Analyze Solving recurrence relation by

substitution and Generating unctions T2:19-19.5

L50-L52Analyze and apply the methods to Solve In homogeneous Recurrence Relations

AnalyzeCharacteristics roots solution of Inhomogeneous Recurrence Relation

T2:19.6-19.9

L53 Understand the methods of graphs Understand

Graph Theory: Representation of Graphhttp://nptel.ac.in/courses/106106094/14

T1:20-20.5

L54 Understand the methods of DFS UnderstandDFS,http://nptel.ac.in/courses/106106094/16

T2:20.6-20.9

MLR Institute of Technology, Dundigal, Hyd-500043 Page 65

Page 66: 9.12TUTORIALQUESTIONS - MLR Institute of Web viewDepartment of CSE. Department of CSE. MLR Institute of Technology, Dundigal, Hyd-500043Page 2. MLR Institute of Technology, Dundigal,

Department of CSE

L55 Understand the methods of BFS, UnderstandBFS,http://nptel.ac.in/courses/106106094/16

T2:21.1-21.6

L56-L58 Understand the methods of planar Graphs. Understand

Spanning Trees, planar Graphs. http://nptel.ac.in/courses/106106094/17

T2:22-22.6

L59-L60 Understand the methods of Graph Theory and Applications Understand graphs T2:23-23.6

L61-L62 Understand the methods of Isomorphism and Sub graphs Understand

Basic Concepts Isomorphism and Sub graphshttp://nptel.ac.in/courses/106106094/15

T2:24-24.7

L63 Understand the methods of Multi graphs and Euler circuits, Understand

Multi graphs and Euler circuits, http://nptel.ac.in/courses/106106094/15

T2:25-25.8

L64 Understand the methods of Hamiltonian graphs, Understand

Hamiltonian graphs, http://nptel.ac.in/courses/106106094/15

T2:26-26.7

L65 Understand the methods of Chromatic Numbers Understand Chromatic Numbers. T2:27-27.7

12.9 MAPPING COURSEOBJECTIVES LEADING TO THE ACHIEVEMENT OF PROGRAM OUTCOMES

Course ObjectiveProgram Outcomes

A B C D E F G H I J k L M NI S SII S HIII SIV H SV H

S= Supportive H = Highly Related

12.10 MAPPING COURSE OUTCOMES LEADING TO THE ACHIEVEMENT OF PROGRAMOUTCOMES

Course OutcomesProgram Outcomes

A B C D E F G H I J k L M N1 S S2 H3 S S S4 H5 S S

S =Supportive H = Highly Related

MLR Institute of Technology, Dundigal, Hyd-500043 Page 66

Page 67: 9.12TUTORIALQUESTIONS - MLR Institute of Web viewDepartment of CSE. Department of CSE. MLR Institute of Technology, Dundigal, Hyd-500043Page 2. MLR Institute of Technology, Dundigal,

Department of CSE

12.11 OBJECTIVE QUESTIONS:

UNIT–I1. P<->Q=(P->Q)∩ (Q->P)

A. EquivalentB. DifferentC. unequalD. can not determinedAnswer A

2. A product of variables and their negations is calledA. Elementary sumB. Elementary productC. SumD. ProductAnswer B

3. A sum of variables and their negations is calledA. Elementary sumB. Elementary productC. SumD. ProductAnswer A

4. A sum of elementary product variables and their negations is calledA. DNFB. CNFC. PDNFD. PCNFAnswer A

5. A product of elementary sum variables and their negations is calledA. DNFB. CNFC. PDNFD. PCNFAnswer B

6. !(!P)=A. !PB. PC. 1D. QAnswer B

7 Which of the following statement is the negation of the statement, “2 is even and –3 is negative”?A. 2 is even and –3 is not negative. B. 2 is odd and –3 is not negative.C. 2 is even or –3 is not negative.D. 2 is odd or –3 is not negative. Answer D

8. The equivalent value of the statement formula = (P V (~ P^ Q)) is [ ]A. ~ P ^ ~ Q B. ~P V ~Q

MLR Institute of Technology, Dundigal, Hyd-500043 Page 67

Page 68: 9.12TUTORIALQUESTIONS - MLR Institute of Web viewDepartment of CSE. Department of CSE. MLR Institute of Technology, Dundigal, Hyd-500043Page 2. MLR Institute of Technology, Dundigal,

Department of CSE

C. ~P->~Q D. P V Q Answer A

9. A proposition that is neither a tautology nor a contradiction is called [ ]A. Converse B. Inference C. Contingency D. NegationAnswer C

10. The inverse of P -> Q [ ]A. P->Q B. ~ P ->~ Q C. ~P=>~Q D. P->~Q Answer B

11. S1: P V~ (P ^Q) and S2: (P ^ Q) ^ ~ (P ^ Q).Which of the following statement is correct?A. S1 is true and S2 is false B. both are true C. S1 is false and s2 is true D. both are false Answer A

12. If there are 'n' distinct components in a statement formula, then the possible number of combinations of truth value in the truth table is [ ]A. 3n B. 2n C. 4n D. None Answer B

13. PVf ≡A. pB. ~pC. fD. T Answer B

14. (PQ) ^(QP) =A. PQ B. ~PQ C. P↔Q D. ~P ↔ QAnswer C

15. The conjunctive normal form of ofPV(PQ) isA. Q ^(~PVQ)B. P^(~PVQ) C. (~PVQ) D. (PQ) Answer B

16. The statement form (p ⇔ r) ⇒ (q ⇔ r) is equivalent to A. [(∼p ∨ r) ∧ (p ∨∼r)] ∨∼[(∼q ∨ r) ∧ (q ∨∼r)]B. ∼[(∼p ∨ r) ∧ (p ∨∼r)] ∧ [(∼q ∨ r) ∧ (q ∨∼r)]

MLR Institute of Technology, Dundigal, Hyd-500043 Page 68

Page 69: 9.12TUTORIALQUESTIONS - MLR Institute of Web viewDepartment of CSE. Department of CSE. MLR Institute of Technology, Dundigal, Hyd-500043Page 2. MLR Institute of Technology, Dundigal,

Department of CSE

C. [(∼p ∨ r) ∧ (p ∨∼r)] ∧ [(∼q ∨ r) ∧ (q ∨∼r)]D. [(∼p ∨ r) ∧ (p ∨∼r)] ∨ [(∼q ∨ r) ∧ (q ∨∼r)]E. ∼[(∼p ∨ r) ∧ (p ∨∼r)] ∨ [(∼q ∨ r) ∧ (q ∨∼r)] Answer E

17. The function ((p ∨ (r ∨ q)) ∧∼(∼q ∧∼r) is equal to the functionA. q∨ rB. ((p∨ r) ∨ q)) ∧ (p ∨ r) C) (p ∧ q) ∨ (p ∧ r)C. (p∨ q) ∧∼(p ∨ r)D. (p∧ r) ∨ (p ∧ q) Answer A

18. The truth table for (p ∨ q) ∨ (p ∧ r) is the same as the truth table for A. (p ∨ q) ∧ (p ∨ r)B. (p∨ q) ∧ rC. (p∨ q) ∧ (p ∧ r)D. p∨ qE. (p∧ q) ∨ pAnswer D

19. The Boolean function [∼(∼p∧q)∧∼(∼p∧∼q)]∨(p∧r) is equal to the Boolean functionA. qB. p∧ rC. p∨ qD. rE. p Answer E

20. Which of the following functions is the constant 1 function?A. ∼p ∨ (p ∧ q)B. (p∧ q) ∨ (∼p ∨ (p ∧∼q))C. (p∧∼q) ∧ (∼p ∨ q)D. ((∼p ∧ q) ∧ (q ∧ r)) ∧∼qE. (∼p ∨ q) ∨ (p ∧ q) Answer B

UNIT- II1. Which of the relations are functions

A. (1,2),(2,3),(3,1)B. (1,2),(2,2),(3,2)C. (1,2),(2,3),(1,1)D. (1,2),(2,2),(3,2),(4,1),(5,3)Answer C

2. Which of the following is false? [ ]A. An abelian group can have a non abelian subgroupB. An abelian group can’t have a subgroupC. An abelian group can have abelian sub groupD. none Answer A

3. A one-to- one function is also known as [ ]A. Injective functionB. Surjective function

MLR Institute of Technology, Dundigal, Hyd-500043 Page 69

Page 70: 9.12TUTORIALQUESTIONS - MLR Institute of Web viewDepartment of CSE. Department of CSE. MLR Institute of Technology, Dundigal, Hyd-500043Page 2. MLR Institute of Technology, Dundigal,

Department of CSE

C. Bijective functionD. NoneAnswer A

4. The relation (1,2), (1,3), (3,1), (1,1), (3,3), (3,2), (1,4), (4,2), (3,4) isA. ReflexiveB. Transitive.C. SymmetricD. Asymmetric Answer B

5. A partial ordered relation is transitive, reflexive andA. AntisymmetricB. BisymmetricC. Anti-ReflexiveD. Asymmetric Answer A

6. Let S= 1. Which of the following is not a subset of P(S) (the power set of S)A. ᴓB. 1C. 1D. ᴓ, 1Answer B

7. The relation ‘divides’ on set of +ve integers isA. SymmetricB. TransitiveC. AsymmetricD. ReflexiveAnswer D

8. Let A=1,2,3,4 and the relation R is R=(1,2),(1,3),(4,2) then R is A. Not antisymmetricB. Not irreflexiveC. TransitiveD. SymmetricAnswer C

9. If A and B are any two sets then A-(A-B) is equal to A. BB. A∩BC. AƯBD. AAnswer B

10. Let P(S) denotes the power set of S. Which of the following is always true A. P(P(S))=P(S) B. P(S)∩P(P(S))=ᶲ C. P(S)∩S=P(S) D. S € P(S)Answer B

11. If A,B,C,D are any four sets then (A∩B)X(C∩D) isequal toA. (AXB)Ư(CXD)B. (AXC)∩(BXD)C. (AƯB)X(CƯD)D. (AXD)∩(BXC)

MLR Institute of Technology, Dundigal, Hyd-500043 Page 70

Page 71: 9.12TUTORIALQUESTIONS - MLR Institute of Web viewDepartment of CSE. Department of CSE. MLR Institute of Technology, Dundigal, Hyd-500043Page 2. MLR Institute of Technology, Dundigal,

Department of CSE

Answer B12. If a relation R on a set A is transitive and irreflexive then it is

A. Anti-SymmetricB. SymmetricC. AsymmetricD. NoneAnswer C

13. The relation ‘is congruent modulo to’ on the set of integers 0,1,2,……10isA. Partial ordering relationB. Equivalence relationC. Symmetric relationD. NoneAnswer B

14. Alattice which has both elements 0and 1 is called a A. Complete lattice B. Modular Lattice C. Boolean Lattice D. Bounded LatticeAnswer D

15. A relation R on a set S is said to be Partial ordering if it isA. Reflexive, Antisymmetric, transitiveB. Reflexive, Asymmetric, transitiveC. Reflexive, symmetric, transitiveD. None of theseAnswer A

16. (AUB)C=

A. AC UBC

B. AC ∩BC

C. (A ∩B)C

D. None of theseAnswer B

17. (A ∩B)C=A. AC UBC

B. AC ∩BC

C. (AUB)C

D. None of theseAnswer A

18. Let A=1,2,3,4 and the relation R is R=(1,2),(1,3),(4,2)then R isA. Not antisymmetricB. TransitiveC. AsymmetricD. Not irreflexiveAnswer B

19. Let A and B be sets with cardinalities m and n respectively.The number of one-one mappings from A to B when m<n isA. mPn

B. nPm

C. mCn

D. nCm

Answer B

MLR Institute of Technology, Dundigal, Hyd-500043 Page 71

Page 72: 9.12TUTORIALQUESTIONS - MLR Institute of Web viewDepartment of CSE. Department of CSE. MLR Institute of Technology, Dundigal, Hyd-500043Page 2. MLR Institute of Technology, Dundigal,

Department of CSE

20. The number of elements in the power set P(S) of the set S= φ, 1,2,3 isA. 2B. 4C. 8D. 6Answer C

UNIT- III1. How many different 8-bit strings is there that begin and end with one?

A. 58B. 60C. 62D. 64

2. In how many ways can be draw a king or a queen from ordinary deck of playing cards?A. 4B. 6C. 8D. 10

3. How many ways can we get a sum of 7 when two distinguishable dice are rolled? A. 4B. 5C. 6D. 7

4. How many ways can we draw a club or a diamond from a pack of cards? A. 24B. 26C. 30D. 32

5. In how many ways can be drawn an ace or a king from an arbitrary deck of playing cards?A. 4B. 5C. 6D. 7

6. How many possible outcomes are there when we roll a pair of dice, one red and one green? A. 36B. 38C. 40D. 42

7. In how many different ways one can answer all the questions of a true- false test consisting of 4 questions? A. 14B. 16C. 18D. 20

8. How many ways 16-bit strings are there containing exactly five 0's?A. 4367

MLR Institute of Technology, Dundigal, Hyd-500043 Page 72

Page 73: 9.12TUTORIALQUESTIONS - MLR Institute of Web viewDepartment of CSE. Department of CSE. MLR Institute of Technology, Dundigal, Hyd-500043Page 2. MLR Institute of Technology, Dundigal,

Department of CSE

B. 4366C. 4369D. 4368

9. from 10 programmers in how many ways can 5 be selected when a particular programmer included every time?A. 126B. 128C. 122D. 124

10. Determine the value of n if nC4=nC3.A. 4B. 5C. 6D. 7

11. Determine the value of n if nCn-2=10.A. 4B. 5C. 6D. 7

12. The number of combinations of n things taken all at a time is A. 0B. 1!C. 2!D. 3!

13. (n+1)!/n! isA. n!B. nC. n+1D. (n+1)!

14. How many words of 3 distinct letters can formed from the letters of the word LAND?A. 20B. 24C. 28D. 32

15. There are 4 black, 3 green, and 5red balls. In how many ways can they be arranged in a row? A. 27720B. 27770C. 27790D. 27710

16. In how many ways can one choose two cards in succession from a deck of 52 cards, such that the first chosen card is not replaced?A. 52 X 50B. 52 X 52C. ()% X 50D. 52 X 51

17. In how many ways can a party of persons arrange themselves around a circular table? A. 6!

MLR Institute of Technology, Dundigal, Hyd-500043 Page 73

Page 74: 9.12TUTORIALQUESTIONS - MLR Institute of Web viewDepartment of CSE. Department of CSE. MLR Institute of Technology, Dundigal, Hyd-500043Page 2. MLR Institute of Technology, Dundigal,

Department of CSE

B. 8!C. 8!D. 9!

18. In how many different ways can the letters of the word ‘MATHEMATICS’ be arranged in such a way that the vowels always come together?A. A.10080B. 4989600C. 120960D. 2880Answer C

19. 2P(n,n-2)=A. P(n,n)B. P(2n,n)C. P(n,1)D. P(n,2n)Answer A

20. C(2n,n+1)+2C(2n,n)+C(2n,n-1)=A. A.C(n+2,n+1)B. C(2n+2,n)C. C(2n+2,n+1)D. C(n-1,n-2)

UNIT-IV1. Find a generating function for ar=the number of non-negative integral solutions to

e1+e2+&.+en=r where 0<=ei.A. (1+X+X2+----+XK+----.)nB. (1+X-X2+----+XK+----)nC. (1-X-X2+----.+XK+----.)nD. (1-X+X2+----+XK+----.)n

2. The coefficient of X9 in (+X3+X8)10 isA. C(9,3)B. C(10,4)C. C(10,3)D. C(11,4)

3. Recurrence relation is also called as a. Difference equationA. reverse equationB. forward equationC. backward equation

4. The recurrence relation an=an-1+5, with a1=2, the sequence isA. 6, 11,16-----B. 7,12,17----C. 8,13,18----D. 9,14,19-----

5. The recurrence relation an=an-1+an-2, with a1=a2=1, the sequence isA. 1,2,3,5,8B. 2,3,5,8,13C. 1,1,2,3,5,8,13D. 2,5,8,13

6. The recurrence relation an=an-1+5, with a=6, the sequence isA. 6, 11,16----

MLR Institute of Technology, Dundigal, Hyd-500043 Page 74

Page 75: 9.12TUTORIALQUESTIONS - MLR Institute of Web viewDepartment of CSE. Department of CSE. MLR Institute of Technology, Dundigal, Hyd-500043Page 2. MLR Institute of Technology, Dundigal,

Department of CSE

B. 7,12,17----C. 8,13,18----D. 9,14,19----

7. Find a generating function for ar=the number of non-negative integralsolutions to e1+e2+&.+en=r where 0<=ei<=1.

A. (1-X)nB. (1+X)nC. XnD. (X-1)n

8. Find the coefficient of X10 in 1/(1-X)5.A. C(14,10)B. C(10,10)C. C(11,11)D. C(13,11)

9. Find the coefficient of X10 in (1+X+X2+X3+&.)2 A. 10 B. 11 C. 12 D. 13

10. Find the coefficient of X10 in A. 1/(1-X3.B. (10)(11)/2 b)(12)(10)/2C. (12)(11)/2D. (10)(10)/2

11. Find a generating function for ar=the number of ways of distributing similar balls into n numbered bones where each box is non-empty.A. (X2+X3+----)nB. (X+X2+X3+----)nC. (1+X3+X4+---)nD. (X+X5+X6+----)n

12. Find a generating function for ar=the number of ways the sum r can be obtained when 2 distinguishable dice are tossed and the first shows an even number and second shows an odd number.A. (X2+X4+X6)(X+X3+ X5)B. (X2+X4)(X+X3- X5)C. (X2+X4-X6)(X+ X5)D. (X2+X6)(X+X3+ X5)

13. Generating function of 1 isA. 1/(1+X)B. 1/(1-X)C. 1/(1-2X)D. 1/(1-3X)

14. Generating function of an isA. /(1-X)B. 1/(1+X)C. 1/(1-aX)D. 1/(1+aX)

15. Generating function of C(k,n ) isA. (1+X)kB. (1+3X)k

MLR Institute of Technology, Dundigal, Hyd-500043 Page 75

Page 76: 9.12TUTORIALQUESTIONS - MLR Institute of Web viewDepartment of CSE. Department of CSE. MLR Institute of Technology, Dundigal, Hyd-500043Page 2. MLR Institute of Technology, Dundigal,

Department of CSE

C. (1+2X)kD. (1-X)k

16. find the particular solution of the difference equation ar+2- 2ar+1+ar=3r+5. A. (1/3)r3+r2 B. (1/2)r3+r2C. (1/4)r3+r2D. (1/5)r3+r2

17. Solve the recurrence relation ar-ar-1-6ar-2=-30, a0=20, a1=-5.A. ar=11.2r+3.5rB. ar=(2+r)4r-1C. ar=1.2r+4.3r+5D. ar=11.(-2)r+4.3r+5

18. Find the particular solution of the difference equation ar-1- 5ar+1+6ar=5r. A. (1/6)5rB. (1/5)5rC. (1/6)6rD. (1/6)4r

19. Find the particular solution of the difference equation ar-1- 5ar+1+6ar=5r A. (1/6)5rB. (1/5)5rC. (1/6)6rD. (1/6)4r

20. Generating function of (n+3)(n+2)(n) isA. 6/(1-X)2B. 6X/(1-X)4C. 6/(1-X)4D. 6/(1-3X)3

UNIT- V1. A regular graph of degree has no lines.

A. 0B. 1C. 2D. 3

2. Suppose G is a non-directed graph with 12 edges. If G has 6 vertices each of degree 3 and the rest have degree less than 3, what is the minimum number of vertices G can have?A. 6B. 9C. 12D. 15

3. The maximum degree of any vertex in a simple graph with n vertices isA. nB. n+1C. n-1D. n+2

4. What is the largest number of vertices in a graph with 35 edges if all vertices are degree at least 3.A. 9B. 11

MLR Institute of Technology, Dundigal, Hyd-500043 Page 76

Page 77: 9.12TUTORIALQUESTIONS - MLR Institute of Web viewDepartment of CSE. Department of CSE. MLR Institute of Technology, Dundigal, Hyd-500043Page 2. MLR Institute of Technology, Dundigal,

Department of CSE

C. 8D. 10

5. A graph G has 21 edges, 3 vertices of degree 4 and other vertices of degree 3. Find the number of vertices in G.A. 10B. 1C. 12D. 13

6. The maximum number of edges in a simple graph with n vertices isA. n(n-1)/2B. (n-1)/2C. n(n+1)/2D. n(n-1)

7. A graph which allows more than one edge to join a pair of vertices is calledA. Simple graphB. MultigraphC. null graphD. weighted graph

8. A graph G with no self loops is called aA. Simple graphB. MultigraphC. null graphD. weighted graph

9. A graph having loops but no multiple edges called aA. Simple graphB. MultigraphC. pseudo graphD. weighted graph

10. A simple graph G, in which every pair of distinct vertices are adjacent is calledA. Simple graphB. MultigraphC. null graphD. complete graph

11. Which data structure is used to implement DFS?A. StackB. queueC. listD. heap

12. A binary tree T has n leaves. The number of nodes of degree 2 in T isA. n-1B. nC. n+1D. 2n

13. The process of accessing data stored in a tape is similar to manipulating data on aA. stackB. listC. queueD. heap

14. Find the order of vertices of G are processed using a DFS algorithm beginning at vertex

MLR Institute of Technology, Dundigal, Hyd-500043 Page 77

Page 78: 9.12TUTORIALQUESTIONS - MLR Institute of Web viewDepartment of CSE. Department of CSE. MLR Institute of Technology, Dundigal, Hyd-500043Page 2. MLR Institute of Technology, Dundigal,

Department of CSE

A. ABEFDGCHB. ABFEDGHC C. ABEFGDHCD. ABEFDGHC

15. Find the order of vertices of G are processed using a DFS algorithm beginning at vertex A. ABEFDGCHB. ABFEDGHC C. ABEFCGHDD. ABEFDGHC

16. DFS stands forA. Depth First SearchB. Deep First SearchC. Dangling First SearchD. Dig First Search

17. Which data structure is used to implement DFS?A. StackB. queueC. listD. heap

18. Pre-order is nothing butA. Depth First Order B. Breadth First order C. Topological orderD. Linear order

19. The vertices visit order in DFS is (starting point is at 1)A. 12485367 B. 12485637C. 12845637D. 12458637

20. Which is used to find the connected component of graph?A. BFSB. DFSC. Simple GraphD. TreeA. Eular

12.12 TUTORIALS QUESTION BANK

S. No QuestionsBlooms

TaxonomyLevel

Course Outcome

UNIT–I

1.a) Prove the following logical equivalence without using truth

table(p->q) ∩ [!q∩ (r Ư!q)]!(qƯp)b) Construct the truth table [(p->q)ʌ(q->r)]->(p->r)

Apply

2.

a) Show that the scope of the quantifiers(x)[(P(x)↔Q(x)ʌ (Ǝx)/R(X)]ʌS(x)b) Obtain the principles disjunction normal form of[( pʌ q)ᴠ(˥p ʌ r)ᴠ(qʌ r)]

Apply

MLR Institute of Technology, Dundigal, Hyd-500043 Page 78

Page 79: 9.12TUTORIALQUESTIONS - MLR Institute of Web viewDepartment of CSE. Department of CSE. MLR Institute of Technology, Dundigal, Hyd-500043Page 2. MLR Institute of Technology, Dundigal,

Department of CSE

3.a) [(pƯq) ∩ (p->r) ∩ (q->r)]->r find out the tautologyb) (!p->r) ∩ (qp) construct the disjunctive normal forms Evaluate

UNIT–II

1.

a) If A,B are twos sets,then AƯB=(A-B)ƯBb)The directed graph of the relationR=(1,1),(1,3),(2,1),(2,3),(2,4),(3,1),(3,2),(4,1)on the set1,2,3,4is

Apply

2. Designthe Hassedia gramforX=2,3,6,24,36,48andrelation besuchthat xy,ifxdividesy(Level6) Analyze

3

Verify the following relationRonX=1,2,3,4,isequivalence relationornot?ExplainR=(1,1),(1,4),(4,1),(2,2),(2,3),(3,4),(3,3),(3,2),(4,3),(4,4)(Level4)

Evaluate

4. ApplytheHassediagramforthedivisibilityRelationonthesetAin thefollowingA=1,2,3,4,6, 8,9,12,18,24.(Level6) Apply

UNIT-III

1. Inhowmanydifferentwayscanacommitteeof5teachersand4studentsbeselectedfrom9teachersand15students?( Level5)

2.

a)Inhowmanydifferentorderscan3menand3women beseatedin arrow of6seatsifanyonemaysitinanyofthe seatsthefirstandlastseatsmustbefilledbymenand womenareseatedalternativelyallembersofthesame sixseatedinadjacentseats.

b)Howmany6digitnumbersaretherewithexactlyone5?Level5)

3. Determine the coefficient of X5 in (a+bx+cx2)10.(Level5)

4. Use Binomial identities to evaluate1.2.3=2.3.4+………+(n-2)(n-1)n..(Level5)

UNIT-IV

1.a) Solve the recurrence relationS(n)+10s(n-1)+9s(n-2)=0 where s(0)=3,s(1)=1.b) Find the coefficient of x8 in 1/(x-3)(x-2)2.

Analyze

2. Solve the recurrence relationan-7an-1+10an-2=0 for n≥2.(Level3) Apply

3. Find the coefficient of x20 in (x3+x4+x5+…..)5. Apply

UNIT-V

1. If G=(V.E) is a loop –free undirected graph with |v|= n≥3 and |E|>(n-1)c2+2 then prove that G has a Hamiltonian cycle.(Level4) Analyze

2. . Derive an algoritham for constructing Euler circuits in directed Graphs Level5) Analyze

3.ApplyKruskal’sandPrim’salgorithmtodetermineaminimalspanningtreeforthe weightedgraphshownbelow:(Level3)

Apply

MLR Institute of Technology, Dundigal, Hyd-500043 Page 79

Page 80: 9.12TUTORIALQUESTIONS - MLR Institute of Web viewDepartment of CSE. Department of CSE. MLR Institute of Technology, Dundigal, Hyd-500043Page 2. MLR Institute of Technology, Dundigal,

Department of CSE

12.13 ASSIGNMENTS QUESTION BANK

S. No QuestionsBlooms

TaxonomyLevel

Course Outcome

UNIT–I

1.A=1,2,---5 and define r on A by xryiff x+1=y thendefine r2=rr, r3=r2r etc.Find (i) r(ii)r2(iii)r3.

Apply

2.Construct the truth tables

(i) [(p->q)ʌ(q->r)]->(p->r)(ii) (!P<->!Q)<->(Q<->R)

Apply

3. Show that the canonical product of sum of the formula(p->(q∩r)) ∩ (!p->(!q∩!r)) is π(1,2,3,4,5,6). Evaluate

4. Show that the scope of the quantifiers(x)[(P(x)↔Q(x)ʌ (Ǝx)/R(X)]ʌS(x) Evaluate

5.Obtain the principles conjunction normal form forFollowingi)(˥p->r) ʌ(qp)ii)[( p ᴠ q)ʌ(p->r)ʌ(q->r)->r](Level4)

Evaluate

UNIT–II

1.Simplify the following:(i) A∩(B-A)(ii)(A∩B)U(A∩B)U (A∩B∩C∩D).

Apply

2.

If N is the set of positive integers and R is the set of realnumbers, examine which of the following sets is empty:(i)x/x€N,2x+7=3(ii)x/x€R,x2+4=6(iii)x/x€R,x2+3x+3=0(Level6)

Apply

3.Using Venn diagrams, investigate the truth or falsity of(i)A∆(B∩C)=(A∆B)∩(A∆C)(ii)A-(BUC)=(A-B)∩ (A-C)

(Level6)

Analyze

4.

a) Verifythe followingrelationRonX=1,2,3,4,isequivalence relationornot?b) ExplainR= (1,1),(1,4), (4,1),(2,2),(2,3), (3,4),(3,3), (3,2), (4,3) ,(4,4)

Evaluate

5. ApplytheHassediagramforthedivisibilityRelationonthesetAin thefollowing A=1,2,3,4,6, 8,9,12,18,24.(Level6) Apply

UNIT-III

1. Inhowmanydifferentwayscanacommitteeof5teachersand4studentsbeselectedfrom9teachersand15students?( Level5)

MLR Institute of Technology, Dundigal, Hyd-500043 Page 80

Page 81: 9.12TUTORIALQUESTIONS - MLR Institute of Web viewDepartment of CSE. Department of CSE. MLR Institute of Technology, Dundigal, Hyd-500043Page 2. MLR Institute of Technology, Dundigal,

Department of CSE

2.

a)Inhowmanydifferentorderscan3menand3women beseatedin arrow of6seatsifanyonemaysitinanyofthe seatsthefirstandlastseatsmustbefilledbymenand womenareseatedalternativelyallembersofthe same six seatedinadjacentseats.

b)Howmany6digitnumbersaretherewithexactlyone5?( Level5)

3.DiscoverthenumberofpermutationsofthelettersofthewordMASSASAUGA.Inhowmanyofthese,allfourA’saretogether?HowmanyofthembeginwithS?(Level3)

4. Enumerating r-permutations without repetitionsP(n,r)=n(n-1)(n-2)-----(n-r+1)=n!/(n-r)!(Level5)

5.Find the sum of coefficient of odd powers of x in(1+x+x2+x3)7

UNIT-IV

1. Solve D(k)-8D(k-1)+16d(k-2)=0 where D(2)=16 and D(3)=80. (Level4) Analyze

2. Solve the recurrence relationT(k)-7T(k-1)+10T(k-2)=k2+1 and T(0)=4,T(1)=17.(Level3) Apply

3.In how many ways can we distribute 24 pencils to 4 children so that each child gets atleast 4 pencils but no more than nine?

(Level3)Apply

4.Use generating function to determine how many four elements subsets S=1,2,3,----15 contain no constructive integers. Apply

UNIT-V

1. Let G=(V,E) be a sample graph of order n and size m.Ifm>(n/2)2, prove that G cannot be a bipartite graph.(Level4) Analyze

2. Determinethatthe bipartitegraphsarePlanargraphs.(Level5) Evaluate

3. Prove the every connected graph having a traigle as aSubgraph is at least 3-chromotic number(Level5) Evaluate

4. Show that a planner graph with 8 vertices and 13 edges is not2-colorable(Level5)

Analyze

5. Prove that every cubic graph is 4-colorable.(Level3) Apply

MLR Institute of Technology, Dundigal, Hyd-500043 Page 81

Page 82: 9.12TUTORIALQUESTIONS - MLR Institute of Web viewDepartment of CSE. Department of CSE. MLR Institute of Technology, Dundigal, Hyd-500043Page 2. MLR Institute of Technology, Dundigal,

Department of CSE

13. OBJECT ORIENTED PROGRAMMING USING C++ ( A10508)

13.0 COURSE DESCRIPTION

Course Title OBJECT ORIENTED PROGRAMMING USING C++Course Code A10508Regulation R15 Autonomous

Course StructureLectures Tutorials Practicals Credits

3 1 3 3Course Coordinator L LakshmiTeam of Instructors B Madhura Vani/P Ram Mohan Rao/Dr Arun Dalton

13.1 COURSE OVERVIEW: Covers the fundamental concepts of object-oriented programming. Includes object-

oriented concepts such as data abstractions, encapsulation, inheritance, dynamic binding, and polymorphism, and uses C++ as the vehicle for illustrating and implementing these concepts. The object-oriented paradigm is systematically employed in the design of all concepts. Effects of this methodology on software maintenance, extensibility, and reuse will be covered. Significant programming/design projects are assigned

13.2 PREREQUISITES:

Level Credits Periods /Week

PrerequisitesUG 3 6 Sound knowledge of mathematics, basics of C programming

13.3 MARKS DISTRIBUTION:

Session Marks University EndExam Marks Total Marks

There shall be 2 midterm examinations. Each midterm examination consists of subjective type and objective type tests. The subjective test is for 10 marks, with duration of 1 hour. Subjective test of each semester shall contain 4 questions; the student has to answer 2 questions, each carrying5marks.The objective type test is for 10 marks with duration of 20minutes. It consists of10 multiple choice and 10 objective type questions, the student have to answer all the questions and each carry half mark.First midterm examination shall be conducted for the first two and half units of syllabus and second midterm examination shall be conducted for the remaining portion.Five marks are earmarked for assignments. There shall be two assignments in every theory course. Marks shall be awarded considering the average of two assignments in each course.

75 100

13.4 EVALUATION SCHEME:

S. No Component Duration Marks1 I Mid Examination 80 minutes 202 I Assignment --- 53 II Mid Examination 80 minutes 204 II Assignment ---- 5

MLR Institute of Technology, Dundigal, Hyd-500043 Page 82

Page 83: 9.12TUTORIALQUESTIONS - MLR Institute of Web viewDepartment of CSE. Department of CSE. MLR Institute of Technology, Dundigal, Hyd-500043Page 2. MLR Institute of Technology, Dundigal,

Department of CSE

5 External Examination 3 hours 75

13.5 a) COURSE OBJECTIVES: I. To impart concepts of object oriented programming.

II. To explain C++ features such as composition of objects, operator overloading, dynamic memory allocation, inheritance and polymorphism, file I/O, exception handling, etc.

III. To facilitate students to build C++ classes using appropriate encapsulation and design principles.

IV. To familiarize various concepts of exception handling, templates and virtual functions.

V. Be able to program using more advanced C++ features such as composition of objects, operator overloads, dynamic memory allocation, inheritance and polymorphism, file I/O, exception handling, etc.

VI. Be able to build C++ classes using appropriate encapsulation and design principles.

b) COURSE OUTCOMES:

Sl. No. Course Outcomes Blooms Level

1. Differentiate between structures oriented programming and object oriented programming.

Apply[Level 4]

2. Use object oriented programming language like C++ and associated libraries to develop object oriented programs

Evaluate[Level 6]

3.Apply various object oriented features like inheritance, data abstraction, encapsulation and polymorphism to solve various computing problems using C++ language.

Understand[Level 3]

4. Apply concepts of operator-overloading, constructors and destructors. Evaluate[Level 5]

5. Design programs using oops concepts related to real world Apply[Level 6]

6. Design programs which can handle exceptions Understand[Level 6]

13.6 HOW PROGRAM OUTCOMES AREASSESSED:

Program Outcomes Level Proficiencyassessed by

AAn ability to apply the knowledge of mathematics, Computing, Science and engineering to solve Computer Science and Engineering problems. (Fundamental engineering analysis skills).

S Assignment Exercise

BAn ability to design and conduct engineering experiments, as well as to analyze and interpret data. (Information retrieval skills). H Solving Practical

Example

CAn ability to design and construct a hardware and software system, component, or process to meet desired needs, within realistic constraints. (Creative skills).

S Building Prototypes with Simulators

DGraduates will demonstrate an ability to visualize and work on laboratory and Multi-disciplinary tasks individually or as a member within the teams. (team work)

H Mini or Micro Projects

EAn ability to demonstrate skills to use the techniques, modern engineering Tools, Software and equipments necessary to analyze computer engineering Problems. (Engg. Problem solving Skills)

SEasy approach for

ComplexProblem

F An understanding of professional, social and ethical responsibility N --G An ability to recognize the global issues like green initiatives and

alternate energy sources and to take technology to villages and to SMini Projects

MLR Institute of Technology, Dundigal, Hyd-500043 Page 83

Page 84: 9.12TUTORIALQUESTIONS - MLR Institute of Web viewDepartment of CSE. Department of CSE. MLR Institute of Technology, Dundigal, Hyd-500043Page 2. MLR Institute of Technology, Dundigal,

Department of CSE

recognize the rural requirements. (Engg. Application Skills)

HThe broad education necessary to understand the impact of engineering solutions in a global, economic, environmental, and societal context.

S BuildPrototypes

I

Graduate will develop confidence for self-education and acquire new knowledge in the computing discipline and ability and practice for Multi-disciplinary tasks as a member within the teams

SSeminars

Presentation, Micro Projects

J To communicate effectively N

K An ability to use the techniques, skills and modern engineering tools necessary for Engineering practice. S

Assigning Exercises, Development of Prototypes, Mini

Projects

LGraduates are able to participate and succeed in competitive examination like GRE, GATE, TOEFL, GMAT etc.(Continuing Education)

H Higher Studies

M

The use of current application software and the design and use of operating systems and the analysis, design, testing and documentation of computer programs for the use in Computer Science and engineering technologies.

H Major Project

N An ability to setup an enterprise.(Employment Skills) S PlacementN= None S= Supportive H = Highly Relate

13.7 SYLLABUS

UNIT – I Introduction to Object Oriented Programming, Structure of C++ program, Tokens, Keywords, Identifiers and Constants, Basic Data Types, Operators and Type Conversions.Functions: Returning values from functions. Reference arguments, Overloaded function, Inline function, Default arguments, returning by reference.UNIT - IIObject and Classes: Specifying a Class, Member function, Nesting of Member functions, Arrays in a Class, Memory Allocation for Objects, Static Members and Member Functions, Array of Objects, Friend Functions, Pointers to Members.Constructors and Destructors: Parameterized Constructor, Copy Constructor, Dynamic Constructor, Destructors.UNIT – III Operator Overloading: Overloading unary, binary operators, data conversion, pitfalls of operators overloading and conversion keywords, Explicit and Mutable. Inheritance: Derived class and Base class, Single Inheritance, Multiple Inheritance, Multilevel Inheritance, Hierarchical Inheritance, Virtual Base Classes, Abstract Classes, Constructor in Derived Classes.UNIT – IVPointer: Introduction, Pointers to Objects, this Pointer, Pointers to Derived Class, Virtual Functions, Pure Virtual Functions.Streams and Files: C++ Streams, Stream Classes, Unformatted IO Operations, Formatted Console IO Operations, Managing Output with Manipulators.UNIT VFiles: Classes for File Handling, File Pointer, Updating a File, Error Handling in Files.Templates and Exception Handling: Class Templates, Function Templates, Exception Handling Mechanism, And Components of STL: Containers, Algorithms, Iterators.

TEXTBOOKS:

MLR Institute of Technology, Dundigal, Hyd-500043 Page 84

Page 85: 9.12TUTORIALQUESTIONS - MLR Institute of Web viewDepartment of CSE. Department of CSE. MLR Institute of Technology, Dundigal, Hyd-500043Page 2. MLR Institute of Technology, Dundigal,

Department of CSE

1. Object Oriented Programming with C++, E Balaguruswamy, Third Edition, and McGraw Hill Publications.

REFERENCES:1. Object Oriented Programming in C++ by Robert Lafore Techmedia Publication. 2. Object Oriented Programming in C++ Saurav Sahay Oxford University Press.

13.8 COURSEPLAN: At the end of the course, the students are able to achieve the following course learning outcomes:

Lecture No. Course Learning Outcomes Blooms Level Topics to be covered Reference

L1 List basic concepts of oops 1 Introduction to Object Oriented Programming T1: Ch 1.4

L2Understand concepts of oopsApply oops concepts to real world objects

2 Introduction to Object Oriented Programming T1: Ch 1.5

L3 Understand the structure of c++ 2 Structure of C++ program T1: Ch 2.6

L4 Identify tokens,keywords 3 Tokens, Keywords T1: Ch 3.2 to 3.3

L5 Use of identifiers and constants 3 Identifiers and Constants T1: Ch 3.4

L6 Define basic data types 1 Basic Data Types T1: Ch 3.5

L7 Analyze operators 4 Operators and Type Conversions T1: Ch 3.13

L8 Importance of type conversion 5 Operators and Type Conversions T1: Ch 3.18

L9 Apply functions to find gcd of two numbers 3 Functions: Returning values from

functionsT1: Ch 4.1 to

4.2

L10 Create a c++ program to solve tower of Hanoi 6 Functions: Returning values from

functionsT1: Ch 4.3 to

4.5

L11 Use reference arguments to swap two numbers 3 Reference arguments T1: Ch 4.5

L12 Express the overloading of functions with example 2 Overloaded function T1: Ch 4.9

L13 Write a program to add numbers using inline functions 6 Inline function T1: Ch 4.6

L14 Define default arguments 1 Default arguments T1: Ch 4.7

L15 Write a program to find a factorial using returning by ]reference 6 returning by reference T1: Ch 3.5

L16 Write a program to find a factorial using returning by reference 6 returning by reference T1: Ch 4.10

L17 Understanding classes and objects with real world entities 2 Object and Classes: T1: Ch 5.1

MLR Institute of Technology, Dundigal, Hyd-500043 Page 85

Page 86: 9.12TUTORIALQUESTIONS - MLR Institute of Web viewDepartment of CSE. Department of CSE. MLR Institute of Technology, Dundigal, Hyd-500043Page 2. MLR Institute of Technology, Dundigal,

Department of CSE

L18 Create a program to display a person details using class and object 6 Specifying a Class, Member

functionT1: Ch 5.2 to

5.4

L19 Write a n example of nesting of member functions 6 Nesting of Member functions T1: Ch 5.7

L20 Write a program to use arrays in a class 6 Arrays in a Class T1: Ch 5.9

L21 Write a program to allocate memory to objects dynamically 6 Memory Allocation for Objects T1: Ch 5.10

L22 Write a program to illustrate the use of static members in a program 6 Static Members and Member

Functions T1: Ch 5.12

L23 Describe array of objects 2 Array of Objects T1: Ch 5.13

L24 Create a program to make use of friend function 6 Friend Functions, Pointers to

Members T1: Ch 5.15

L25 Design an application that uses constructors and destructors 6 Constructors and Destructors: T1: Ch 6.1 to

6.2

L26 Reframe the above application with Parameterized Constructor 5 Parameterized Constructor, Copy

Constructor T1: Ch 6.3

L27 Reframe the above application with Parameterized Constructor 5 Dynamic Constructor, Destructors T1: Ch 6.4

L28 Explain operator overloading 2 Operator Overloading: T1: Ch 7.1 to 7.2

L29 Write a program to overload unary and binary operators 6 Overloading unary, binary

operatorsT1: Ch 7.3 to

7.4

L30 Explain data conversion 2 data conversion T1: Ch 7.8

L31 Write the pitfall of operator overloading 6 pitfalls of operators overloading T1: Ch 7.7

L32 Use conversion keywords to convert from float to int 4 conversion keywords T1: Ch 7.8

L33 Express explicit and mutable storage specifiers 6 Explicit and Mutable T1: Ch 7.8

L34 Define inheritance 1 Inheritance: Derived class and Base class

T1: Ch 8.1 to 8.2

L35 Write a program to implement single inheritance 6 Single Inheritance T1: Ch 8.3

L36 Write a program to implement multiple inheritance 6 Multiple Inheritance, Multilevel

Inheritance,T1: Ch 8.4 to

8.5

L37 Write a program to implement hierarchical inheritance 6 Hierarchical Inheritance T1: Ch 8.7

L38 Define virtual base classes 1 Virtual Base Classes T1: Ch 8.9

L39 Understand the usage of abstract classes 2,4 Abstract Classes T1: Ch 8.10

L40 Apply constructors in derived classes 3 Constructor in Derived Classes T1: Ch 8.11

L41 Define pointer 1 Pointer: Introduction, Pointers to Objects

T1: Ch 9.1 to 9.2

MLR Institute of Technology, Dundigal, Hyd-500043 Page 86

Page 87: 9.12TUTORIALQUESTIONS - MLR Institute of Web viewDepartment of CSE. Department of CSE. MLR Institute of Technology, Dundigal, Hyd-500043Page 2. MLR Institute of Technology, Dundigal,

Department of CSE

L42 Write a program to use this pointer 6 this Pointer T1: Ch 9.4

L43 Apply pointers in derived classes 3 Pointers to Derived Class T1: Ch 9.5

L44 Design an application that uses virtual functions 6 Virtual Functions T1: Ch 9.6

L45 Differentiate between virtual and pure virtual functions 4 Pure Virtual Functions T1: Ch 9.7

L46 Define streams and files 1 Streams and Files: T1: Ch 10.2 to 10.3

L47 Examine the I/o streams and stream classes 5 C++ Streams, Stream Classes T1: Ch 10.3

L48 Demonstrate the use of I/O operations 2 Unformatted IO Operations T1: Ch 10.4

L49 Create program that uses console I/O functions 6 Formatted Console IO Operations T1: Ch 10.5

L50 Create program that uses console I/O functions Formatted Console IO Operations T1: Ch 10.5

L51 Show the output with manipulators Managing Output with Manipulators T1: Ch 10.6

L52 Show the output with manipulators Managing Output with Manipulators T1: Ch 10.6

L53 Define file 1 Files T1: Ch 11.1 to 11.2

L54 Write a program using classes for file handling 6 Classes for File Handling T1: Ch 11.3

L55 Understanding the usage of file pointer 2,4 File Pointer T1: Ch 11.6

L56 Write a program to update the content of file 6 Updating a File T1: Ch 11.8

L57 Select the functions used for error handling 5 Error Handling in Files T1: Ch 11.9

L58 Define templates and exception handling 1 Templates and Exception

Handling T1: Ch 12.1

L59 Define class templates 1 Class Templates T1: Ch 12.2

L60 Differentiate between class and function templates 2 Function Templates T1: Ch 12.3

L61 Write a program to find factorial by using exception handling 6 Exception Handling Mechanism T1: Ch 13.1 to

13.2

L62 Define components of STL 1 And Components of STL T1: Ch 14.1 to 14.2

L63 Make use of containers and write a program to implement vector container 6 Containers, Algorithms, Iterators T1: Ch 14.3 to

14.6

L64 Make use of iterators and write a program to implement vector container 6 Containers, Algorithms, Iterators T1: Ch 14.3 to

14.6

MLR Institute of Technology, Dundigal, Hyd-500043 Page 87

Page 88: 9.12TUTORIALQUESTIONS - MLR Institute of Web viewDepartment of CSE. Department of CSE. MLR Institute of Technology, Dundigal, Hyd-500043Page 2. MLR Institute of Technology, Dundigal,

Department of CSE

13.9 MAPPING COURSE OBJECTIVE LEADING TO THE ACHIEVEMENT OF PROGRAM OUTCOMES

Course Objectives

ProgramA B C D E F G H I J K L M N

I S SII S S HIII H S S HIV H S SV S H SVI H HS=Supportive H = HighlyRelated

13.10 MAPPING COURSE OUTCOMES LEADING TO THE ACHIEVEMENT OF PROGRAM OUTCOMES

CourseObjectives

ProgramA B C D E F G H I J K L M N

I SII S HIII H SIV S H SV S S HVI S H H

13.11 OBJECTIVE BITS

UNIT-11. What is the size of wchar_t in C++?

A. 2B. 4C. 2 or 4D. based on the number of bits in the systemAnswer DExplanation: Compiler wants to make CPU as more efficient in accessing the next value.

2. Pick the odd one outA. array typeB. character typeC. Boolean typeD. integer typeAnswer AExplanation: Array type is not the basic type and it is constructed using the basic type.

3. Which data type is used to represent the absence of parameters?A. intB. shortC. voidD. float

MLR Institute of Technology, Dundigal, Hyd-500043 Page 88

Page 89: 9.12TUTORIALQUESTIONS - MLR Institute of Web viewDepartment of CSE. Department of CSE. MLR Institute of Technology, Dundigal, Hyd-500043Page 2. MLR Institute of Technology, Dundigal,

Department of CSE

Answer CExplanation: void will not return anything.

4. What does a escape code represent?A. alertB. backslashC. tabD. form feedAnswer AExplanation: Because a is used to produce a beep sound.

5. Which type is best suited to represent the logical values?A. integerB. BooleanC. characterD. all of the mentionedAnswer BExplanation: Logical values can be either true or false, so the boolean type is suited for it.

6. Identify the user-defined types from the following?A. enumerationB. classesC. both a and bD. intAnswer CExplanation: They must be defined by the users before use unlike the other types which are readily available.

7. Which of the following statements are true? int f(float)A. f is a function taking an argument of type int and returning a floating point

numberB. f is a function taking an argument of type float and returning a integer.C. f is a function of type floatD. none of the mentionedAnswer BExplanation: The argument that is passed to a function f is of float type and the function finally retruns a value that id is of integer type.

8. The value 132.54 can represented using which data type?A. doubleB. voidC. intD. boolAnswer AExplanation: The given value is with decimal points, so float or double can be used.

9. When a language has the capability to produce new data type mean, it can be called asA. overloadedB. extensibleC. encapsulatedD. reprehensibleAnswer BExplanation: Extensible is used to add new features to C++.

10. Pick the odd one out.

MLR Institute of Technology, Dundigal, Hyd-500043 Page 89

Page 90: 9.12TUTORIALQUESTIONS - MLR Institute of Web viewDepartment of CSE. Department of CSE. MLR Institute of Technology, Dundigal, Hyd-500043Page 2. MLR Institute of Technology, Dundigal,

Department of CSE

A. integer, character, boolean, floatingB. enumeration, classesC. integer, enum, voidD. arrays, pointer, classesAnswer CExplanation: Option a consists of all fundamental types, option b consists of user-definied types and option d consists of derived types but option c is a mixture.

11. Where does the execution of the program starts?A. user-defined functionB. main functionC. void functionD. none of the mentionedAnswer BExplanation: Normally the execution of the program in c++ starts from main only.

12. What are mandatory parts in function declaration?A. return type, function nameB. return type, function name, parametersC. both a and bD. none of the mentionedAnswer AExplanation: In a function, return type and function name are mandatory all else are just used as a choice.

13. Which of the following is used to terminate the function declaration?A. :B. b C. ;D. none of the mentionedAnswer CExplanation: None.

14. How many max number of arguments can present in function in c99 compiler?A. 99B. 90C. 102D. 127Answer DExplanation: None.

15. Which is more effective while calling the functions?A. call by valueB. call by referenceC. call by pointerD. None of the mentionedAnswer BExplanation: In the call by reference, it will just copy the address of the variable to access it, so it will reduce the memory in accessing it.

16. What is the output of this program?#include <iostream>

using namespace std;void mani()void mani()

MLR Institute of Technology, Dundigal, Hyd-500043 Page 90

Page 91: 9.12TUTORIALQUESTIONS - MLR Institute of Web viewDepartment of CSE. Department of CSE. MLR Institute of Technology, Dundigal, Hyd-500043Page 2. MLR Institute of Technology, Dundigal,

Department of CSE

cout<<"hai"; int main() mani(); return 0; A. haiB. haihaiC. compile time errorD. none of the mentionedAnswer CExplanation: We have to use the semicolon to declare the function in line 3. If we did means, the program will execute.

17. What is the output of this program? #include <iostream> using namespace std; void fun(int x, int y) x = 20; y = 10; int main() int x = 10; fun(x, x); cout << x; return 0; A. 10B. 20C. compile time errorD. none of the mentionedAnswer AExplanation: In this program, we called by value so the value will not be changed, So the output is 10Output:$ g++ fun.cpp$ a.out10

18. What is the scope of the variable declared in the user definied function?A. whole programB. only inside the blockC. both a and bD. none of the mentionedAnswer BExplanation: The variable is valid only in the function block as in other.

19. How many minimum number of functions are need to be presented in c++?A. 0B. 1

MLR Institute of Technology, Dundigal, Hyd-500043 Page 91

Page 92: 9.12TUTORIALQUESTIONS - MLR Institute of Web viewDepartment of CSE. Department of CSE. MLR Institute of Technology, Dundigal, Hyd-500043Page 2. MLR Institute of Technology, Dundigal,

Department of CSE

C. 2D. 3Answer BExplanation: The main function is the mandatory part, it is needed for the execution of the program to start.

20. If the user didn’t supply the value, what value will it take?A. default valueB. rise an errorC. both a & bD. none of the mentionedAnswer AExplanation: If the user didn’t supply the value means, the compiler will take the given value in the argument list.

21. Where can the default parameter be placed by the user?A. leftmostB. rightmostC. both a & bD. None of the mentionedAnswer BExplanation: None.

22. Which value will it take when both user and default values are given?A. user valueB. default valueC. custom valueD. None of the mentionedAnswer AExplanation: The default value will be used when the user value is not given, So in this case, the user value will be taken.

23. What is the output of this program? #include <iostream> using namespace std; void func(int a, bool flag = true) if (flag == true ) cout << "Flag is true. a = " << a; else cout << "Flag is false. a = " << a; int main() func(200, false); return 0; A. Flag is true. a = 200B. Flag is false. a = 100C. Flag is false. a = 200D. Flag is true. a = 100

MLR Institute of Technology, Dundigal, Hyd-500043 Page 92

Page 93: 9.12TUTORIALQUESTIONS - MLR Institute of Web viewDepartment of CSE. Department of CSE. MLR Institute of Technology, Dundigal, Hyd-500043Page 2. MLR Institute of Technology, Dundigal,

Department of CSE

Answer CExplanation: In this program, we are passing the value, as it evaluates to false, it produces the output as following.Output:$ g++ def.cpp$ a.outFlag is false. a = 200

24. What is the output of this program? #include <iostream> #include <string> using namespace std; string askNumber(string prompt = "Please enter a number: "); int main() string number = askNumber(); cout << "Here is your number: " << number; return 0; string askNumber(string prompt) string number; cout << prompt; cin >> number; return number; A. 5B. 6C. the number you enteredD. compile time errorAnswer CExplanation: In this program, we are getting a number and printing it.Output:$ g++ def1.cpp$ a.outPlease enter a number:5Here is your number:5

25. What is the output of this program? #include <iostream> using namespace std; void Values(int n1, int n2 = 10) using namespace std; cout << "1st value: " << n1; cout << "2nd value: " << n2; int main() Values(1); Values(3, 4);

MLR Institute of Technology, Dundigal, Hyd-500043 Page 93

Page 94: 9.12TUTORIALQUESTIONS - MLR Institute of Web viewDepartment of CSE. Department of CSE. MLR Institute of Technology, Dundigal, Hyd-500043Page 2. MLR Institute of Technology, Dundigal,

Department of CSE

return 0; A. 1st value: 1

2nd value: 10 1st value: 3 2nd value: 4

B. 1st value: 1 2nd value: 10 1st value: 3 2nd value: 10

C. compile time errorD. none of the mentionedAnswer AExplanation: In this program, We are passing the values as by default values rules it is working.Output:$ g++ def2.cpp$ a.out1st value: 12nd value: 101st value: 32nd value: 4

26. What we can’t place followed by the non-default arguments?A. trailing argumentsB. default argumentsC. both a & bD. None of the mentionedAnswer BExplanation: None.

27. If we start our function call with default arguments means, what will be proceeding arguments?A. user argumentB. empty argumentsC. default argumentsD. None of the mentionedAnswer CExplanation: As a rule, the default argument must be followed by default arguments only.

28. What is the default return type of a function?A. intB. voidC. floatD. charAnswer BExplanation: None.

29. What is the output of this program? #include <iostream> using namespace std; int func(int m = 10, int n)

MLR Institute of Technology, Dundigal, Hyd-500043 Page 94

Page 95: 9.12TUTORIALQUESTIONS - MLR Institute of Web viewDepartment of CSE. Department of CSE. MLR Institute of Technology, Dundigal, Hyd-500043Page 2. MLR Institute of Technology, Dundigal,

Department of CSE

int c; c = m + n; return c; int main() cout << func(5); return 0; A. 15B. 10C. compile time errorD. None of the mentionedAnswer CExplanation: We can’t use the user argument in front of the default argument.

UNIT-21. Where does the object is created?

A. classB. constructorC. destructorD. attributesAnswer AExplanation: In class only all the listed items except class will be declared.

2. How to access the object in the class?A. scope resolution operatorB. ternary operatorC. direct member access operatorD. none of the mentionedAnswer CExplanation: Objects in the method can be accessed using direct member access operator which is (.).

3. Which of these following members are not accessed by using direct member access operator?A. publicB. privateC. protectedD. Both b & cAnswer DExplanation: Because of the access given to the private and protected, We can’t access them by using direct member access operator.

4. What is the output of the following program? #include <iostream> using namespace std; class Box public : double length; double breadth; double height;

MLR Institute of Technology, Dundigal, Hyd-500043 Page 95

Page 96: 9.12TUTORIALQUESTIONS - MLR Institute of Web viewDepartment of CSE. Department of CSE. MLR Institute of Technology, Dundigal, Hyd-500043Page 2. MLR Institute of Technology, Dundigal,

Department of CSE

; int main( ) Box Box1; double volume; Box1.height = 5; Box1.length = 6; Box1.breadth = 7.1; volume = Box1.height * Box1.length * Box1.breadth; cout << "Volume of Box1 : " << volume <<endl; return 0; A. 210B. 213C. 215D. 217Answer BExplanation: In the above program, we are calculating the area of the cube by using the cube formulaOutput:$ g++ obj1.cpp$ a. out213

5. What is the output of the program? #include <iostream> using namespace std; class Rect int x, y; public: void set_values (int,int); int area () return (x * y); ; void Rect::set_values (int a, int b) x = a; y = b; int main () Rect recta, rectb; recta.set_values (5, 6); rectb.set_values (7, 6); cout << "recta area: " << recta.area(); cout << "rectb area: " << rectb.area(); return 0; A. recta area: 30 rectb area: 42

MLR Institute of Technology, Dundigal, Hyd-500043 Page 96

Page 97: 9.12TUTORIALQUESTIONS - MLR Institute of Web viewDepartment of CSE. Department of CSE. MLR Institute of Technology, Dundigal, Hyd-500043Page 2. MLR Institute of Technology, Dundigal,

Department of CSE

B. recta area: 20 rectb area: 34C. recta area: 30 rectb area: 21D. none of the mentionedAnswer AExplanation: We are calculating the area of rectangle by two objects.

6. Pick out the other definition of objects.A. member of the classB. associate of the classC. attribute of the classD. instance of the classAnswer DExplanation: None.

7. How many objects can present in a single class?A. 1B. 2C. 3D. as many as possibleAnswer DExplanation: Because a class may contain any number of objects according to it’s compliance.

8. What is the output of this program? #include <iostream> using namespace std; class sample private: int var; public: void input() cout << var; void output() cout << "Variable entered is "; cout << var << "\n"; ; int main() sample object; object.input(); object.output(); object.var(); return 0; a. Enter an integer 5A. Variable entered is 5B. runtime errorC. error

MLR Institute of Technology, Dundigal, Hyd-500043 Page 97

Page 98: 9.12TUTORIALQUESTIONS - MLR Institute of Web viewDepartment of CSE. Department of CSE. MLR Institute of Technology, Dundigal, Hyd-500043Page 2. MLR Institute of Technology, Dundigal,

Department of CSE

D. none of the mentionedAnswer CExplanation: While using private member, you can’t access it variable.

9. Which special character s used to mark the end of class?A. ;B. :C. #D. $Answer AExplanation: None.

10. What is the output of this program? #include <iostream> using namespace std; class number int i; public: int geti(); void puti(int j); ; int number::geti() return i; void number::puti(int j) i = j; int main() number s; s.puti(10); cout << s.geti( ); return 0; A. 10B. 11C. 20D. 22Answer AExplanation: We are getting the number and copying it to j and printing it.Output:$ g++ obj2.cpp$ a.out10

11. How many kinds of classes are there in c++?A. 1B. 2C. 3

MLR Institute of Technology, Dundigal, Hyd-500043 Page 98

Page 99: 9.12TUTORIALQUESTIONS - MLR Institute of Web viewDepartment of CSE. Department of CSE. MLR Institute of Technology, Dundigal, Hyd-500043Page 2. MLR Institute of Technology, Dundigal,

Department of CSE

D. 4Answer BExplanation: There are two kinds of classes in c++. They are absolute class and concrete class.

12. What is meant by polymorphism?A. class having many formsB. class having only single formC. class having two formsD. none of the mentionedAnswer AExplanation: Polymirphism is literally means class having many forms.

13. How many types of inheritance are there in c++?A. 2B. 3C. 4D. 5Answer DExplanation: There are five types of inheritance in c++. They are single, Multiple, Hierarchical, Multilevel, Hybrid.

14. What is meant by containership?A. class contains objects of other class types as its membersB. class contains objects of other class types as its objectsC. both a & bD. none of the mentionedAnswer AExplanation: None.

15. How many types of constructor are there in C++?A. 1B. 2C. 3D. 4Answer CExplanation: There are three types of constructor in C++. They are Default constructor, Parameterized constructor, Copy constructor.

16. How many constructors can present in a class?A. 1B. 2C. 3D. multipleAnswer DExplanation: There can be multiple constructors of the same class, provided they have different signatures.

17. What should be the name of constructor?A. same as objectB. same as memberC. same as classD. none of the mentionedAnswer CExplanation: None.

18. What does derived class does not inherit from the base class?

MLR Institute of Technology, Dundigal, Hyd-500043 Page 99

Page 100: 9.12TUTORIALQUESTIONS - MLR Institute of Web viewDepartment of CSE. Department of CSE. MLR Institute of Technology, Dundigal, Hyd-500043Page 2. MLR Institute of Technology, Dundigal,

Department of CSE

A. constructor and destructorB. friendsC. operator = () membersD. all of the mentionedAnswer DExplanation: The derived class inherit everything from the base class except the given things.

19. Which rule will not affect the friend function?A. private and protected members of a class cannot be accessed from outsideB. private and protected member can be accessed anywhereC. both a & bD. None of the mentionedAnswer AExplanation: Friend is used to access private and protected members of a class from outside the same class.

20. Which keyword is used to declare the friend function?A. firendB. friendC. classfriendD. myfriendAnswer BExplanation: None.

21. What is the syntax of friend function?A. friend class1 Class2;B. friend class;C. friend classD. None of the mentionedAnswer AExplanation: In option a, the class2 is the friend of class1 and it can access all the private and protected members of class1.

22. What is the output of this program? #include <iostream> using namespace std; class Box double width; public: friend void printWidth( Box box ); void setWidth( double wid ); ; void Box::setWidth( double wid ) width = wid; void printWidth( Box box ) box.width = box.width * 2; cout << "Width of box : " << box.width << endl; int main( )

MLR Institute of Technology, Dundigal, Hyd-500043 Page 100

Page 101: 9.12TUTORIALQUESTIONS - MLR Institute of Web viewDepartment of CSE. Department of CSE. MLR Institute of Technology, Dundigal, Hyd-500043Page 2. MLR Institute of Technology, Dundigal,

Department of CSE

Box box; box.setWidth(10.0); printWidth( box ); return 0; A. 40B. 5C. 10D. 20Answer DExplanation: We are using the friend function for printwidth and multiplied the width value by , So we got the output as 20Output:$ g++ friend.cpp$ a.out20

23. What is the output of this program? #include <iostream> using namespace std; class sample int width, height; public: void set_values (int, int); int area () return (width * height); friend sample duplicate (sample); ; void sample::set_values (int a, int b) width = a; height = b; sample duplicate (sample rectparam) sample rectres; rectres.width = rectparam.width * 2; rectres.height = rectparam.height * 2; return (rectres); int main () sample rect, rectb; rect.set_values (2, 3); rectb = duplicate (rect); cout << rectb.area(); return 0; A. 20B. 16

MLR Institute of Technology, Dundigal, Hyd-500043 Page 101

Page 102: 9.12TUTORIALQUESTIONS - MLR Institute of Web viewDepartment of CSE. Department of CSE. MLR Institute of Technology, Dundigal, Hyd-500043Page 2. MLR Institute of Technology, Dundigal,

Department of CSE

C. 24D. None of the mentionedAnswer CExplanation: In this program, we are using the friend function for duplicate function and calculating the area of the rectangle.Output:$ g++ friend1.cpp$ a.out24

24. What is the output of this program? #include <iostream> using namespace std; class sample; class sample1 int width, height; public: int area () return (width * height); void convert (sample a); ; class sample private: int side; public: void set_side (int a) side = a; friend class sample1; ; void sample1::convert (sample a) width = a.side; height = a.side; int main () sample sqr; sample1 rect; sqr.set_side(6); rect.convert(sqr); cout << rect.area(); return 0; A. 24B. 35C. 16

MLR Institute of Technology, Dundigal, Hyd-500043 Page 102

Page 103: 9.12TUTORIALQUESTIONS - MLR Institute of Web viewDepartment of CSE. Department of CSE. MLR Institute of Technology, Dundigal, Hyd-500043Page 2. MLR Institute of Technology, Dundigal,

Department of CSE

D. 36Answer DExplanation: In this program, we are using the friend for the class and calculating the area of the square.Output:$ g++ friend2.cpp$ a.out36

25. What is the output of this program? #include <iostream> using namespace std; class base int val1, val2; public: int get()

val1 = 100; val2 = 300;

friend float mean(base ob); ; float mean(base ob) return float(ob.val1 + ob.val2) / 2; int main() base obj; obj.get(); cout << mean(obj); return 0; A. 200B. 150C. 100D. 300Answer AExplanation: In this program, We are finding the mean value by declaring the function mean as a friend of class base.Output:$ g++ friend3.cpp$ a.out200

26. What is the output of this program? #include <iostream> using namespace std; class sample private:

MLR Institute of Technology, Dundigal, Hyd-500043 Page 103

Page 104: 9.12TUTORIALQUESTIONS - MLR Institute of Web viewDepartment of CSE. Department of CSE. MLR Institute of Technology, Dundigal, Hyd-500043Page 2. MLR Institute of Technology, Dundigal,

Department of CSE

int a, b; public: void test() a = 100; b = 200; friend int compute(sample e1); ; int compute(sample e1) return int(e1.a + e1.b) - 5; int main() sample e; e.test(); cout << compute(e); return 0; A. 100B. 200C. 300D. 295Answer DExplanation: In this program, we are finding a value from the given function by using the friend for compute function.Output:$ g++ friend4.cpp$ a.out295

27. Pick out the correct statement.A. A friend function may be a member of another class.B. A friend function may not be a member of another class.C. A friend function may or may not be a member of another class.D. None of the mentionedAnswer CExplanation: None.

28. Where does keyword ‘friend’ should be placed?A. function declarationB. function definitionC. main functionD. None of the mentionedAnswer AExplanation: The keyword friend is placed only in the function declaration of the friend function and not in the function definition because it is used to access the member of a class.

UNIT-3 1. The address of a variable temp of type float is

MLR Institute of Technology, Dundigal, Hyd-500043 Page 104

Page 105: 9.12TUTORIALQUESTIONS - MLR Institute of Web viewDepartment of CSE. Department of CSE. MLR Institute of Technology, Dundigal, Hyd-500043Page 2. MLR Institute of Technology, Dundigal,

Department of CSE

A. *tempB. *tempC. float& tempD. float temp&Answer B

2. What is the output of the following codechar symbol[3]=‘a’,‘b’,‘c’;for (int index=0; index<3; index++)cout << symbol [index];A. a b cB. “abc”C. AbcD. ‘abc’ Answer C

3. The process of building new classes from existing one is called ______.A. PolymorphismB. StructureC. InheritanceD. CascadingAnswer C

4 If a class C is derived from class B, which is derived from class A, all through publicinheritance, then a class C member function can accessA. protected and public data only in C and B. B. protected and public data only in C. C. private data in A and B. D. protected data in A and B. Answer D

5 If the variable count exceeds 100, a single statement that prints “Too many” isA. if (count<100) cout << “Too many”; B. if (count>100) cout >> “Too many”; C. if (count>100) cout << “Too many”; D. None of these. Answer C

6 Usually a pure virtual functionA. has complete function body. B. will never be called. C. will be called only to delete an object. D. is defined only in derived class. Answer D

7 To perform stream I/O with disk files in C++, you shouldA. open and close files as in procedural languages. B. use classes derived from ios. C. use C language library functions to read and write data. D. include the IOSTREAM.H header file. Answer B

8 Overloading the function operatorA. requires a class with an overloaded operator. B. requires a class with an overloaded [ ] operator. C. allows you to create objects that act syntactically like functions. D. usually make use of a constructor that takes arguments.

MLR Institute of Technology, Dundigal, Hyd-500043 Page 105

Page 106: 9.12TUTORIALQUESTIONS - MLR Institute of Web viewDepartment of CSE. Department of CSE. MLR Institute of Technology, Dundigal, Hyd-500043Page 2. MLR Institute of Technology, Dundigal,

Department of CSE

Answer A8 In C++, the range of signed integer type variable is ________

a. 0 to216

b. 215to 215−1B. 27to 27−1C. 0 to 28

Answer B9 Ifx5, y2 thenx∧yequals________.(where ∧ is a bit wise XOR operator)

A. 00000111B. 10000010C. 10100000D. 11001000Answer A

11 If an array is declared asint a[4] = 3, 0, 1, 2, then values assigned to a[0] & a[4] will be ________A. 3, 2B. 0, 2C. 3, 0D. 0, 4Answer C

10 Mechanism of deriving a class from another derived class is known as____A. PolymorphismB. Single InheritanceC. Multilevel InheritanceD. Message PassingAnswer C

11 RunTime Polymorphism is achieved by ______A. Friend functionB. Virtual functionC. Operator overloadingD. Function overloadingAnswer B

14. A function call mechanism that passes arguments to a function by passing a copy of the values of the arguments is __________A. call by nameB. call by valueC. call by referenceD. call by value resultAnswer B

15. In C++, dynamic memory allocation is accomplished with the operator ____A. NewB. ThisC. malloc( )D. deleteAnswer A

16. If we create a file by ‘ifstream’, then the default mode of the file is _________A. ios :: outB. ios :: inC. ios :: app

MLR Institute of Technology, Dundigal, Hyd-500043 Page 106

Page 107: 9.12TUTORIALQUESTIONS - MLR Institute of Web viewDepartment of CSE. Department of CSE. MLR Institute of Technology, Dundigal, Hyd-500043Page 2. MLR Institute of Technology, Dundigal,

Department of CSE

D. ios :: binaryAnswer B

17 A variable defined within a block is visibleA. from the point of definition onward in the program. B. from the point of definition onward in the function. C. from the point of definition onward in the block. D. throughout the function. Answer C

18 The break statement causes an exitA. from the innermost loop only.B. only from the innermost switch.C. from all loops & switches.D. from the innermost loop or switch.Answer D

19 Which of the following cannot be legitimately passed to a functionA. A constant.B. A variable.C. A structure. D. A header file.Answer D

20 A property which is not true for classes is that theyA. are removed from memory when not in use. B. permit data to be hidden from other classes. C. bring together all aspects of an entity in one place. D. Can closely model objects in the real world. Answer C

21 You can read input that consists of multiple lines of text usingA. the normal cout << combination. B. the cin.get( ) function with one argument. C. the cin.get( ) function with two arguments. D. the cin.get( ) function with three arguments. Answer C

22 The keyword friend does not appear inA. the class allowing access to another class. B. the class desiring access to another class. C. the private section of a class. D. the public section of a class. Answer C

23 The process of building new classes from existing one is calledA. Structure.B. InheritanceC. PolymorphismD. Template.Answer B

24 If you wanted to sort many large objects or structures, it would be most efficient toA. place them in an array & sort the array. B. place pointers to them in an array & sort the array. C. place them in a linked list and sort the linked list. D. place references to them in an array and sort the array. Answer C

MLR Institute of Technology, Dundigal, Hyd-500043 Page 107

Page 108: 9.12TUTORIALQUESTIONS - MLR Institute of Web viewDepartment of CSE. Department of CSE. MLR Institute of Technology, Dundigal, Hyd-500043Page 2. MLR Institute of Technology, Dundigal,

Department of CSE

25 Which statement gets affected when i++ is changed to ++i?A. i = 20; i++; B. for (i = 0; i<20; i++) C. a = i++; D. while (i++ = 20) cout <<i; Answer A

26 A friend function to a class, C cannot accessA. private data members and member functions. B. public data members and member functions. C. protected data members and member functions. D. the data members of the derived class of C. Answer D

27 The operator that cannot be overloaded isA. ++B. ::C. ( )D. ~Answer B

28 A struct is the same as a class except thatA. there are no member functions. B. all members are public. C. cannot be used in inheritance hierarchy. D. it does have a this pointer. Answer C

29 Pure virtual functionsA. have to be redefined in the inherited class.B. cannot have public access specification. C. are mandatory for a virtual class. D. None of the above. Answer A

30 Additional information sent when an exception is thrown may be placed inA. the throw keyword. B. the function that caused the error. C. the catch block. D. an object of the exception class. Answer C

UNIT-4 1. What does the following statement mean?

A. int (*fp)(char*)pointer to a pointer

B. pointer to an array of charsC. pointer to function taking a char* argument and returns an intD. function taking a char* argument and returning a pointer to intAnswer CExplanation: None.

2. The operator used for dereferencing or indirection is ____A. *B. &C. ->

MLR Institute of Technology, Dundigal, Hyd-500043 Page 108

Page 109: 9.12TUTORIALQUESTIONS - MLR Institute of Web viewDepartment of CSE. Department of CSE. MLR Institute of Technology, Dundigal, Hyd-500043Page 2. MLR Institute of Technology, Dundigal,

Department of CSE

D. –>>Answer AExplanation: None.

3. Choose the right option string* x, y;A. x is a pointer to a string, y is a stringB. y is a pointer to a string, x is a stringC. both x and y are pointer to string typesD. none of the mentionedAnswer AExplanation: * is to be grouped with the variables not the data types.

4. Which one of the following is not a possible state for a pointer.A. hold the address of the specific objectB. point one past the end of an objectC. zeroD. point to a tyeAnswer DExplanation: A pointer can be in only 3 states a,b and c.

5. Which of the following is illegal?A. int *ip;B. string s, *sp = 0;C. int i; double* dp = &i;D. int *pi = 0;Answer CExplanation: dp is initialized int value of i.

6. What will happen in this code? int a = 100, b = 200; int *p = &a, *q = &b; p = q;A. b is assigned to aB. p now points to bC. a is assigned to bD. q now points to aAnswer BExplanation: Assigning to refrence changes the object to which the refrence is bound. advertisements

7. What is the output of this program? #include <iostream> using namespace std; int main() int a = 5, b = 10, c = 15; int *arr[ ] = &a, &b, &c; cout << arr[1]; return 0; A. 5B. 10C. 15D. it will return some random number

MLR Institute of Technology, Dundigal, Hyd-500043 Page 109

Page 110: 9.12TUTORIALQUESTIONS - MLR Institute of Web viewDepartment of CSE. Department of CSE. MLR Institute of Technology, Dundigal, Hyd-500043Page 2. MLR Institute of Technology, Dundigal,

Department of CSE

Answer DExplanation: Array element cannot be address of auto variable. It can be address of static or extern variables.

8. The correct statement for a function that takes pointer to a float, a pointer to a pointer to a char and returns a pointer to a pointer to a integer isA. int **fun(float**, char**)B. int *fun(float*, char*)C. int ***fun(float*, char**)D. int ***fun(*float, **char)Answer CExplanation: None.

9. What is the output of this program? #include <iostream> using namespace std; int main() char arr[20]; int i; for(i = 0; i < 10; i++) *(arr + i) = 65 + i; *(arr + i) = '\0'; cout << arr; return(0); A. ABCDEFGHIJB. AAAAAAAAAAC. JJJJJJJJD. none of the mentionedAnswer AExplanation: Each time we are assigning 65 + i. In first iteration i = 0 and 65 is assigned. So it will print from A to J.$ g++ point1.cpp$ a.outABCDEFGHIJ

10. What is the output of this program? #include <iostream> using namespace std; int main() char *ptr; char Str[] = "abcdefg"; ptr = Str; ptr += 5; cout << ptr; return 0; A. fgB. cdefC. defgD. abcd

MLR Institute of Technology, Dundigal, Hyd-500043 Page 110

Page 111: 9.12TUTORIALQUESTIONS - MLR Institute of Web viewDepartment of CSE. Department of CSE. MLR Institute of Technology, Dundigal, Hyd-500043Page 2. MLR Institute of Technology, Dundigal,

Department of CSE

Answer AExplanation: Pointer ptr points to string ‘fg’. So it prints fg.Output:$ g++ point.cpp$ a.outfg

11. How many groups of output of operation are there in c++?A. 1B. 2C. 3D. 4Answer BExplanation: There are two groups of output operation in c++. They are formatted output and unformatted output.

12. Pick out the correct objects about the instantiation of output stream.A. coutB. cerrC. clogD. All of the mentionedAnswer DExplanation: cout, cerr and clog are the standard objects for the instantiation of output stream class.

13. What is meant by ofstream in c++?A. Writes to a fileB. Reads from a fileC. Both a & bD. None of the mentionedAnswer AExplanation: of stream is a stream class to write on files.

14. What is the output of this program? #include <iostream> using namespace std; int main () char str[] = "Steve jobs"; int val = 65; char ch = 'A'; cout.width (5); cout << right; cout << val << endl; return 0; A. Steve jobsB. AC. 65D. 65Answer DExplanation: In this program, We are printing the five spaces and then we are printing the value of 65.Output:

MLR Institute of Technology, Dundigal, Hyd-500043 Page 111

Page 112: 9.12TUTORIALQUESTIONS - MLR Institute of Web viewDepartment of CSE. Department of CSE. MLR Institute of Technology, Dundigal, Hyd-500043Page 2. MLR Institute of Technology, Dundigal,

Department of CSE

$ g++ ous.cpp$ a.out 65

15. What is the output of this program? #include <iostream> using namespace std; int main () int n; n = 43; cout << hex << n << endl; return 0; A. 2cB. 2bC. 20D. 50Answer BExplanation: In this program, We are printing the hexadecimal value of the given decimal number by using hex function.Output:$ g++ ous1.cpp$ a.out2b

16. What is the output of this program in the “test.txt” file? #include <fstream> using namespace std; int main () long pos; ofstream outfile; outfile.open ("test.txt"); outfile.write ("This is an apple",16); pos = outfile.tellp(); outfile.seekp (pos - 7); outfile.write (" sam", 4); outfile.close(); return 0; A. This is an appleB. appleC. sampleD. This is a sampleAnswer DExplanation: In this program, We are changing the ap to sam by using the pos function.Output:$ g++ ous2.cpp$ a.outThis is a sample

MLR Institute of Technology, Dundigal, Hyd-500043 Page 112

Page 113: 9.12TUTORIALQUESTIONS - MLR Institute of Web viewDepartment of CSE. Department of CSE. MLR Institute of Technology, Dundigal, Hyd-500043Page 2. MLR Institute of Technology, Dundigal,

Department of CSE

17. What is the output of this program? #include <iostream> using namespace std; int main () int n; n = -77; cout.width(4); cout << internal << n << endl; return 0; A. 77B. -77C. – 77D. None of the mentionedAnswer CExplanation: In this program, We are using the internal function and moving the 77 to one position.Output:$ g++ ous3.cpp$ a.out– 77

18. What is the output of this program? #include <iostream> #include <locale> using namespace std; int main() locale mylocale(""); cout.imbue( mylocale ); cout << (double) 3.14159 << endl; return 0; A. 3.14B. 3.14159C. ErrorD. None of the mentionedAnswer BExplanation: In this program, We are using the locale and then assigning the type to the value.Output:$ g++ ous4.cpp$ a.out3.14159

19. How many types of output stream classes are there in c++?A. 1B. 2C. 3D. 4Answer C

MLR Institute of Technology, Dundigal, Hyd-500043 Page 113

Page 114: 9.12TUTORIALQUESTIONS - MLR Institute of Web viewDepartment of CSE. Department of CSE. MLR Institute of Technology, Dundigal, Hyd-500043Page 2. MLR Institute of Technology, Dundigal,

Department of CSE

Explanation: There are three output stream classes in c++. They are ostream, of stream and os trstream.

20. What must be specified when we construct an object of class ostream?A. streamB. streambufC. memoryD. None of the mentionedAnswer BExplanation: If you construct an object of class ostream, you must specify a streambuf object to the constructor.

21. Which operator is used to insert the data into file?A. >>B. <<C. <D. None of the mentioned Answer B Explanation: You can write information to a file from your program using the stream insertion operator <<.

22. Which function is used to position back from the end of file object? A. seekg B. seekp C. Both a & b D. None of the mentioned Answer A Explanation: The member function seekg is used to position back from the end of file object.

23. How many objects are used for input and output to a string? A. 1 B. 2 C. 3 D. 4 Answer C Explanation: The stringstream, ostringstream, and istringstream objects are used for input and output to a string.

24. What is the output of this program? #include <iostream> #include <fstream> using namespace std; int main () int length; char * buffer; ifstream is; is.open ("sample.txt", ios :: binary ); is.seekg (0, ios :: end); length = is.tellg(); is.seekg (0, ios :: beg); buffer = new char [length]; is.read (buffer, length); is.close();

MLR Institute of Technology, Dundigal, Hyd-500043 Page 114

Page 115: 9.12TUTORIALQUESTIONS - MLR Institute of Web viewDepartment of CSE. Department of CSE. MLR Institute of Technology, Dundigal, Hyd-500043Page 2. MLR Institute of Technology, Dundigal,

Department of CSE

cout.write (buffer, length); delete[] buffer; return 0; A. This is sampleB. sampleC. ErrorD. Runtime errorAnswer DExplanation: In this program, if the file exist, it will read the file. Otherwise it will throw an exception. A runtime error will occur because the value of the length variable will be “-1” if file doesn’t exist and in line 13 we are trying to allocate an array of size “-1”.

25. What is the output of this program? #include <iostream> using namespace std; int main () char first, second; cout << "Enter a word: "; first = cin.get(); cin.sync(); second = cin.get(); cout << first << endl; cout << second << endl; return 0; A. firstB. secondC. Returns first 2 letter or number from the entered wordD. None of the mentionedAnswer CExplanation: In this program, We are using the sync function to return the first two letters of the entered word.Output:$ g++ stream.cpp$ a.outEnter a word: stevest

26. What is the output of this program? #include<iostream> #include <fstream> using namespace std; int main () ofstream outfile ("test.txt"); for (int n = 0; n < 100; n++) outfile << n;

MLR Institute of Technology, Dundigal, Hyd-500043 Page 115

Page 116: 9.12TUTORIALQUESTIONS - MLR Institute of Web viewDepartment of CSE. Department of CSE. MLR Institute of Technology, Dundigal, Hyd-500043Page 2. MLR Institute of Technology, Dundigal,

Department of CSE

outfile.flush(); cout << "Done"; outfile.close(); return 0; A. DoneB. ErrorC. Runtime errorD. None of the mentionedAnswer AExplanation: In this program, We are using the flush function to update the contents in a file.Output:$ g++ stream1.cpp$ a.outDone

27. What is the output of this program? #include <iostream> using namespace std; int main () int a = 100; double b = 3.14; cout << a; cout << endl; cout << b << endl << a * b; endl (cout); return 0; A. 100B. 3.14C. 314D. All of the mentionedAnswer DExplanation: In this program, We are printing the given value and manipulating the given value by using endl.Output:$ g++ stream2.cpp$ a.out1003.14314

28. By seeing which operator thus this program stops getting the input? #include <iostream> #include <fstream> using namespace std; int main () char ch;

MLR Institute of Technology, Dundigal, Hyd-500043 Page 116

Page 117: 9.12TUTORIALQUESTIONS - MLR Institute of Web viewDepartment of CSE. Department of CSE. MLR Institute of Technology, Dundigal, Hyd-500043Page 2. MLR Institute of Technology, Dundigal,

Department of CSE

streambuf * p; ofstream os ("test.txt"); pbuf = os.rdbuf(); do ch = cin.get(); p -> sputc(ch); while (ch != '.'); os.close(); return 0; A. dot operatorB. insertion operatorC. $ symbolD. None of the mentionedAnswer AExplanation: This program will stop getting the input, When it occurs the dot(.) operator.Output:$ g++ stream3.cpp$ a.outSteve.

29. Which member function is used to determine whether the stream object is currently associated with a file?A. is_openB. bufC. stringD. None of the mentionedAnswer AExplanation: The member function is_open can be used to determine whether the stream object is currently associated with a file.

30. Which header file is used for reading and writing to a file?A. #include<iostream>B. #include<fstream>C. #include<file>D. None of the mentionedAnswer BExplanation: None.

UNIT-51. Which is dependant on template parameter?

A. base classB. abstract classC. methodD. None of the mentionedAnswer AExplanation: None

2. Which value is placed in the base class?A. derived valuesB. default type valuesC. both a & b

MLR Institute of Technology, Dundigal, Hyd-500043 Page 117

Page 118: 9.12TUTORIALQUESTIONS - MLR Institute of Web viewDepartment of CSE. Department of CSE. MLR Institute of Technology, Dundigal, Hyd-500043Page 2. MLR Institute of Technology, Dundigal,

Department of CSE

D. None of the mentionedAnswer BExplanation: We can place the default type values in a base class and overriding some of them through derivation.

3. How many bits of memory needed for internal representation of class?A. 1B. 2C. 4D. no memory neededAnswer DExplanation: classes that contain only type members, nonvirtual function members, and static data members do not require memory at run time.

4. What is the output of this program? #include <iostream> using namespace std; class class0 public: virtual ~class0() protected: char p; public: char getChar(); ; class class1 : public class0 public: void printChar(); ; void class1::printChar() cout << "True" << endl; int main() class1 c; c.printChar(); return 1; A. TrueB. errorC. no outputD. runtime errorAnswer AExplanation: In this program, We are passing the values and inheriting it to the other class and printing the result.$ g++ dert.cpp$ a.outTrue

5. What is the output of this program?

MLR Institute of Technology, Dundigal, Hyd-500043 Page 118

Page 119: 9.12TUTORIALQUESTIONS - MLR Institute of Web viewDepartment of CSE. Department of CSE. MLR Institute of Technology, Dundigal, Hyd-500043Page 2. MLR Institute of Technology, Dundigal,

Department of CSE

#include <iostream> using namespace std; template<typename T>class clsTemplate public: T value; clsTemplate(T i) this->value = i; void test() cout << value << endl; ; class clsChild : public clsTemplate<char> public: clsChild(): clsTemplate<char>( 0 ) clsChild(char c): clsTemplate<char>( c ) void test2() test(); ; int main() clsTemplate <int> a( 42 ); clsChild b( 'A' ); a.test(); b.test(); return 0; A. 42B. AC. 42D. AE. 42Answer CExplanation: In this program, We are passing the values by using the template inheritance and printing it.Output:$ g++ dert.cpp$ a.out42A

MLR Institute of Technology, Dundigal, Hyd-500043 Page 119

Page 120: 9.12TUTORIALQUESTIONS - MLR Institute of Web viewDepartment of CSE. Department of CSE. MLR Institute of Technology, Dundigal, Hyd-500043Page 2. MLR Institute of Technology, Dundigal,

Department of CSE

6. What is the output of this program? #include <iostream> using namespace std; template <class T> class A public: A(int a): x(a) protected: int x; ; template <class T> class B: public A<char> public: B(): A<char>::A(100) cout << x * 2 << endl; ; int main() B<char> test; return 0; A. 100B. 200C. errorD. runtime errorAnswer BExplanation: In this program, We are passing the values and manipulating it by using the template inheritance.Output:$ g++ dert2.cpp$ a.out200

7. What is the output of this program? #include <iostream> using namespace std; template <class type> class Test public: Test(); ~Test(); type Data(type); ; template <class type> type Test<type>::Data(type Var0)

MLR Institute of Technology, Dundigal, Hyd-500043 Page 120

Page 121: 9.12TUTORIALQUESTIONS - MLR Institute of Web viewDepartment of CSE. Department of CSE. MLR Institute of Technology, Dundigal, Hyd-500043Page 2. MLR Institute of Technology, Dundigal,

Department of CSE

return Var0; template <class type> Test<type>::Test() template <class type> Test<type>::~Test() int main(void) Test<char> Var3; cout << Var3.Data('K') << endl; return 0; A. kB. lC. errorD. runtime errorAnswer AExplanation: In this program, We are passing the values and printing it by using template inheritance.Output:$ g++ dert3.cpp$ a.outk

8. What is the output of this program? #include <iostream> using namespace std; class Base public: Base ( ) cout << "1" << endl; ~Base ( ) cout << "2" << endl; ; class Derived : public Base public: Derived ( ) cout << "3" << endl; ~Derived ( )

MLR Institute of Technology, Dundigal, Hyd-500043 Page 121

Page 122: 9.12TUTORIALQUESTIONS - MLR Institute of Web viewDepartment of CSE. Department of CSE. MLR Institute of Technology, Dundigal, Hyd-500043Page 2. MLR Institute of Technology, Dundigal,

Department of CSE

cout << "4" << endl; ; int main( ) Derived x; A. 1234B. 4321C. 1423D. 1342Answer DExplanation: In this program, We are printing the order of execution of constructor and destructor in the class.Output:$ g++ dert4.cpp$ a.out1342

9. How many kinds of entities are directly parameterized in c++?A. 1B. 2C. 3D. 4Answer CExplanation: C++ allows us to parameterize directly three kinds of entities through templates: types, constants, and templates.

10. How many kinds of parameters are there in C++?A. 1B. 2C. 3D. None of the mentionedAnswer CExplanation: There are three kinds of parameters are there in C++. They are type, non-type, template.

11. How many categories of iterators are there in c++?A. 2B. 4C. 5D. 3Answer CExplanation: There are five types of iterators. They are Output, Input, Forward, Random access and Bi-directional.

12. Which of the following can serve as random-access iterator?A. Memory pointerB. Object pointerC. Class pointerD. None of the mentionedAnswer: BExplanation: Because of this, It can serve as any category of iterator.

MLR Institute of Technology, Dundigal, Hyd-500043 Page 122

Page 123: 9.12TUTORIALQUESTIONS - MLR Institute of Web viewDepartment of CSE. Department of CSE. MLR Institute of Technology, Dundigal, Hyd-500043Page 2. MLR Institute of Technology, Dundigal,

Department of CSE

13. What kind of pattern is iterator pattern?A. Design patternB. Sequence patternC. Adapter patternD. All of the mentionedAnswer AExplanation: Iterator pattern is a design pattern in which an iterator is used to traverse a container and access the container’s elements.

14. What is the output of this program? #include <iostream> #include <set> using namespace std; int main() set<int> tst; tst.insert(12); tst.insert(21); tst.insert(32); tst.insert(31); set<int> :: const_iterator pos; for(pos = tst.begin(); pos != tst.end(); ++pos) cout << *pos << ' '; return 0; A. 12 21 32 31B. 12 21 31 32C. 12 21 32D. 12 21 31Answer BExplanation: In this program, We are using const_iterator to sort the datain the set.Output:$ g++ itr.cpp$ a.out12 21 31 32

15. What is the output of this program? #include <iostream> #include <vector> #include<iterator> using namespace std; int main () vector<int> myvector; for (int i = 1; i <= 10; i++) myvector.push_back(i); myvector.erase (myvector.begin() + 6); myvector.erase (myvector.begin(), myvector.begin() + 4); for (unsigned i = 0; i < myvector.size(); ++i) cout << ' ' << myvector[i]; return 0;

MLR Institute of Technology, Dundigal, Hyd-500043 Page 123

Page 124: 9.12TUTORIALQUESTIONS - MLR Institute of Web viewDepartment of CSE. Department of CSE. MLR Institute of Technology, Dundigal, Hyd-500043Page 2. MLR Institute of Technology, Dundigal,

Department of CSE

A. 5 6 7 8 9B. 5 6 8 9 10C. 6 7 8 9 10D. None of the mentionedAnswer BExplanation: In this program, We are erasing the values in the vector based on the given condition.Output:$ g++ itr1.cpp$ a.out5 6 8 9 10

16. What is the output of this program? #include <iostream> #include <iterator> #include <list> using namespace std; int main () list<int> mylist; for (int i = 0; i < 10; i++) mylist.push_back (i * 10); list<int> :: iterator it = mylist.begin(); advance (it, 5); cout << *it << endl; return 0; A. 30B. 40C. 50D. 60Answer CExplanation: In this program, We are printing the sixth element in the list.Output:$ g++ itr2.cpp$ a.out50

17. What is the output of this program? #include <iostream> #include <iterator> #include <list> using namespace std; int main () list<int> firstlist, secondlist; for (int i = 1; i <= 2; i++) firstlist.push_back(i); secondlist.push_back(i * 10);

MLR Institute of Technology, Dundigal, Hyd-500043 Page 124

Page 125: 9.12TUTORIALQUESTIONS - MLR Institute of Web viewDepartment of CSE. Department of CSE. MLR Institute of Technology, Dundigal, Hyd-500043Page 2. MLR Institute of Technology, Dundigal,

Department of CSE

list<int> :: iterator it; it = firstlist.begin(); advance (it, 3); copy (secondlist.begin(), secondlist.end(), inserter(firstlist, it)); for ( it = firstlist.begin(); it != firstlist.end(); ++it ) cout << *it << " "; return 0; A. 10 20 1 2B. 10 20C. 1 2D. 1 10Answer AExplanation: In this iterator, We are copying the first list into second and printing it.Output:$ g++ itr3.cpp$ a.out10 20 1 2

18. What is the output of this program? #include <iostream> #include <iterator> #include <list> using namespace std; int main () list<int> mylist; for (int i = 0; i < 5; i++) mylist.push_back (i * 20); list<int> :: iterator first = mylist.begin(); list<int> :: iterator last = mylist.end(); cout << distance(first, last) << endl; return 0; A. 20B. 100C. 5D. None of the mentionedAnswer CExplanation: In this program, We are printing the number of elements in the list by using distance method.Output:$ g++ itr4.cpp$ a.out5

19. In which type of semantics does c++ implements iterator?A. MemoryB. SizeC. PointerD. None of the mentionedAnswer C

MLR Institute of Technology, Dundigal, Hyd-500043 Page 125

Page 126: 9.12TUTORIALQUESTIONS - MLR Institute of Web viewDepartment of CSE. Department of CSE. MLR Institute of Technology, Dundigal, Hyd-500043Page 2. MLR Institute of Technology, Dundigal,

Department of CSE

Explanation: None.20. By using which operator does point to next element is represent in iterator?

A. ++B. —C. +-D. None of the mentionedAnswer AExplanation: ’++’ operator is used to represent the next element in the iterator.

21. What is meant by sequence point?A. Represent the point of execution in the programB. Represent the whole programC. Represent the beginning of the programD. None of the mentionedAnswer AExplanation: A sequence point defines any point in a computer program’s execution at which it is guaranteed that all side effects of previous evaluations have been performed.

22. Pick out the correct statement about sequence point.A. Sequence point will compile the programB. Sequence point will resolve all the side effectsC. Sequence point will save the program for executionD. None of the mentionedAnswer BExplanation: Sequence point is a point in time at which the dust has settled and all side effects which have been seen so far are guaranteed to be complete.

23. In sequence point, how will the overloaded operators behave like?A. FunctionB. ObjectsC. Instance variableD. None of the mentionedAnswer AExplanation: None.

24. What do input and output objects support?A. Terminated sequencesB. Extracted sequencesC. Null-terminated sequencesD. None of the mentionedAnswer CExplanation: cin and cout support null-terminated sequences as valid containers for sequences of characters.

25. What kind of execution does sequence point allow?A. Non-overlapB. OverlapC. ConcurrentD. None of the mentionedAnswer AExplanation: To resolve all the side-effects in the program, the sequence point should not be overlapped.

26. What is the output of this program? #include <iostream>

MLR Institute of Technology, Dundigal, Hyd-500043 Page 126

Page 127: 9.12TUTORIALQUESTIONS - MLR Institute of Web viewDepartment of CSE. Department of CSE. MLR Institute of Technology, Dundigal, Hyd-500043Page 2. MLR Institute of Technology, Dundigal,

Department of CSE

#include <string> using namespace std; int main () string mys; char mya[20]= "Hello world"; mys = mya; cout << mys << '\n'; return 0; A. Hello worldB. HelloC. ErrorD. Runtime errorAnswer AExplanation: In this program, We converted the char values into the string.Output:$ g++ sts.cpp$ a.outHello world

27. What is the output of this program? #include <iostream> #include <algorithm> #include <vector> using namespace std; bool IsOdd (int i) return (i % 2) == 1; int main () vector<int> myvector; for (int i = 1; i < 10; ++i) myvector.push_back(i); vector<int> :: iterator bound; bound = partition (myvector.begin(), myvector.end(), IsOdd); for (vector<int> :: iterator it = myvector.begin(); it != bound; ++it) cout << ' ' << *it; return 0; A. 1 3 5B. 1 3 9C. 1 9 3 7D. 1 9 3 7 5Answer DExplanation: In this program, We are finding the odd values in the sequence.Output:$ g++ sts1.cpp$ a.out1 9 3 7 5

28. When does the next sequence point start?

MLR Institute of Technology, Dundigal, Hyd-500043 Page 127

Page 128: 9.12TUTORIALQUESTIONS - MLR Institute of Web viewDepartment of CSE. Department of CSE. MLR Institute of Technology, Dundigal, Hyd-500043Page 2. MLR Institute of Technology, Dundigal,

Department of CSE

A. At the beginningB. After a terminating semicolonC. It is a beginning statementD. None of the mentionedAnswer BExplanation: None.

13.12 ASSIGNMENT QUESTION BANK

S. No. QuestionBlooms

Taxonomy Level

Course Outcome

UNIT-1

1 Describe the differences in the implementation of enum data type in ANSI C and C++. Analysis 1

2 Write a function using reference variables as arguments to swap the values of a pair of integers. Create 1

3 Write are the applications of void data type in C++? remember 1

4 Can we assign a void pointer to an int type pointer? If not, why? Now can we achieve this? Apply 1

5 Write a function that creates a vector of user given size M using new operator.. Create 2

6

Write a program to print the following outputs using for loops122333444455555

Create 2

7 Write a program to evaluate the following investment equationV = P(1+r)n Create 3

8 Describe, with examples, the uses of enumeration data types. understand 2

9 The size of a char array that is declared to store a string should be one larger than the number of characters in the string. Justify? Analyze 3

10How do the following statements differ?(a) char *const p;(b) char canal *p;

Analyze 4

UNIT-II

1 How do structures in C and C++ differ Analyze 3

2Can we use the same function name for a member function of a class and an outside function in the same program file? If yes, how are they distinguished? If no, give reasons.

Analyze 3

3 How is a member function of a class defined?. understand 3

4 Define a class String that could work as a user-defined string type. Include constructors that will enable us to create an uninitialized string Knowledge 4

MLR Institute of Technology, Dundigal, Hyd-500043 Page 128

Page 129: 9.12TUTORIALQUESTIONS - MLR Institute of Web viewDepartment of CSE. Department of CSE. MLR Institute of Technology, Dundigal, Hyd-500043Page 2. MLR Institute of Technology, Dundigal,

Department of CSE

5

A book shop maintains the inventory of books that are being sold at the shop. The list includes details such as author, title, price, publisher and stock position. Whenever a customer wants a book, the sales person inputs the title and author and the system searches the list and displays whether it is available or not. If it is not, an appropriate message is displayed. If it is, then the system displays the book details and requests for the number of copies required. If the requested copies are available, the total cost of the requested copies is displayed; otherwise “Required copies not in stock” is displayed.Design a system using a class called books with suitable member functions and constructors. Use new operator in constructors to allocate memory space required.

Create 3

UNIT-III

1 In what order are the class constructors called when a derived class object is created? Apply 3

2 Class D is derived from class B. The class D does not contain any data members of its own. Does the class D require constructors? If yes, why? Evaluate 4

3 What is containership? How does it differ from inheritance? Analyze 4

4We have learned that OOP is well suited for designing simulation programs. Using the techniques and tricks learned so far, design a program that would simulate a simple real-world system familiar to you

Create 5

5 Describe the syntax of the single inheritance in C++. understand 4

UNIT-IV

1

Write a program to read a list containing item name, item code, and cost interactively and produce a three column output as shown below.Name Code Cost Turbo C++ 1001 250.95C primer 905 95.70

Apply 4

2

Write a program which reads a text from the keyboard and displays the following information on the screen in two columns:(a) Number of lines(b) Number of words(c) Number of charactersStrings should be left-justified and numbers should be right-justified in a suitable field width.

Knowledge 5

3 What is the basic difference between manipulators and ioa member functions in implementation? Give examples. Analyze 4

4 Both cin and getline() function can be used for reading a string. If yes justify Evaluate 5

5 Discuss the implications of size parameter in the following statement:cout. write (line, size); understand 4

UNIT-V

1 Write a function template for finding the minimum value contained in an array. Create 5

2

Write a class template to represent a generic vector. Include member functions to perform the following tasks:(a) To create the vector(b) To modify the value of a given element(c) To multiply by a scalar value(d) To display the vector in the following form (10, 20, 30 …)

Create 4

3 A class (or function) template is known as a parameterized class (or function). Justify Evaluate 3

MLR Institute of Technology, Dundigal, Hyd-500043 Page 129

Page 130: 9.12TUTORIALQUESTIONS - MLR Institute of Web viewDepartment of CSE. Department of CSE. MLR Institute of Technology, Dundigal, Hyd-500043Page 2. MLR Institute of Technology, Dundigal,

Department of CSE

4

State which of the following definitions are illegal.(a) temnplateclass city…… ;(b) templateclass city….. (c) templateclass city…… ;

Analyze 1

5 Distinguish between the terms class template and template class. Analyze 3

13.13 TUTORIALS QUESTION BANK

S. No. QuestionBlooms

Taxonomy Level

Course Outcome

UNIT-1

1 Describe the major parts of a C++ program. Understand 1

2 Enumerate the rules of naming variables in C++. How do they differ from ANSI C rules? Justify Justify 1

3 Discuss an approach to the development of procedure-oriented programs. Understand 2

4

Distinguish between the following terms: (a) Objects and classes (b) Data abstraction and data encapsulation(c) Inheritance and polymorphism(d) Dynamic binding and message passing

Analyze 1

5

Write a program to display the following output using a single cout statementMaths = 90Physics = 77Chemistry = 69

Create 1

6 Write a program to read two numbers from the keyboard and display the larger value on the screen. Create 3

7 An unsigned int can be twice as large as the signed int. Justify? Evaluate 1

8 Write a program to input an integer from the keyboard and display on the screen “WELL DONE” that many times. Create 2

9Write a C++ program that will ask for a temperature in Fahrenheit and display it in Celsius. Create 3

UNIT-II

1 What do you mean by dynamic initialization of objects? Why do we need to this? Analysis 1

2

Distinguish between the following two statements: time T2(T1);time T2 = T1;T1 and T2 are objects of time class.

Create

3 List some of the special properties of the constructor functions. remember 2

MLR Institute of Technology, Dundigal, Hyd-500043 Page 130

Page 131: 9.12TUTORIALQUESTIONS - MLR Institute of Web viewDepartment of CSE. Department of CSE. MLR Institute of Technology, Dundigal, Hyd-500043Page 2. MLR Institute of Technology, Dundigal,

Department of CSE

4

Define a class to represent a bank account. Include the following members:Data members:Name of the depositor.Account number.Type of account.Balance amount in the account.Member functions:To assign initial values.To deposit an amount.To withdraw an amount after checking the balance.To display the name and balance.Write a main program to test the program.

Create 4

5

Write a class to represent a vector (a series of float values). Include member functions to perform the following tasks:(a) To create the vector.(b) To modify the value of a given element.(c) To multiply by a scalar value.(d) To display the vector in the form (10, 20, 30 …)Write a program to test your class.

Create 3

UNIT-III

1 What are the different forms of inheritance? Give an example for each. Remember 1

2

We know that a private member of a base class is not inheritable. Is it anyway possible for the objects of a derived class to access the private members of the base class? If yes, how? Remember, the base class cannot be modified.

Analyze 2

3 Describe the syntax of multiple inheritance. When do we use such an inheritance? Apply 3

4

Assume that a bank maintains two kinds of accounts for customers, one called as savings and the other as current account. The savings account provides compound interest and withdrawal facilities but no cheque book facility. The current account provides cheque book facility but no interest. Current account holders should also maintain a minimum balance and if the balance falls below this level a service charge is imposed.Create a class account that stores customer name, account number and type of account. From this derive the classes cur_acct and sav_acct to make them more specific to their requirements. Include necessary member functions in order to achieve the following tasks:(a) Accept the deposit from a customer and update the balance.(b) Display the balance.(c) Compute and deposit interest.(d) Permit withdrawal and update the balance.(e) Check for the minimum balance, impose penalty, necessary and update the balance. Do not use any constructors. Use member functions to initialize class members.

Create 3

5

An educational institution wishes to maintain a database of its employees. The database is divided into a number of classes whose hierarchical relationships are shown in following figure. The figure also shows the minimum information required for each class. Specify all classes and define functions to create the database and retrieve individual information as and when required.

Create 4

UNIT-IV

1 Describe briefly the features of I/O system supported by C++. Understand 3

2 How do the I/O facilities in C++ differ from that in C? Analyze 4

MLR Institute of Technology, Dundigal, Hyd-500043 Page 131

Page 132: 9.12TUTORIALQUESTIONS - MLR Institute of Web viewDepartment of CSE. Department of CSE. MLR Institute of Technology, Dundigal, Hyd-500043Page 2. MLR Institute of Technology, Dundigal,

Department of CSE

3 How do the I/O facilities in C++ differ from that in C? Justify Evaluate 5

4Write a program that reads a text file and creates another file that is identical except that every sequence of consecutive blank spaces is replaced by a single space.

Create 3

5

A file contains a list of telephone numbers in the following formJohn 23456Ahmed 9876…………… …………the names contain only one word and the names and telephone numbers are separated by white spaces. Write program to read this file and output the list in two columns. The names should be left justified and the numbers should be right justified.

Apply 4

UNIT-V

1 Write a function template for finding the minimum value contained in an array. Create 1

2

Write a class template to represent a generic vector. Include member functions to perform the following tasks:(a) To create the vector(b) To modify the value of a given element(c) To multiply by a scalar value(d) To display the vector in the following form (10, 20, 30 …)

Create 2

3 A template can be considered as a kind of macro. Then, what is the difference between them? Analyze 3

4 What is generic programming? How is it implemented in C++? Understand 4

5 A class (or function) template is known as a parameterized class (or function). Justify Evaluate 5

MLR Institute of Technology, Dundigal, Hyd-500043 Page 132

Page 133: 9.12TUTORIALQUESTIONS - MLR Institute of Web viewDepartment of CSE. Department of CSE. MLR Institute of Technology, Dundigal, Hyd-500043Page 2. MLR Institute of Technology, Dundigal,

Department of CSE

14. COMPUTER ORGANIZATION LAB (A10509)

14.1 SYLLABUS:

WEEK 1: Write a program to implement Booth’s Algorithm for Multiplication.

WEEK 2: Write a program to implement Restoring Division Algorithm.

WEEK 3: Write a program to implement Non-Restoring Division Algorithm.

WEEK 4: Write a program to evaluate replacement policy FIFO.

WEEK 5: Write a program to evaluate replacement policy LRU).

WEEK 6: Write a program using Arithmetic and Logical instruction of IA-32 processor for ASCII to

BCD conversion.

WEEK 7: Write a program using Arithmetic and Logical instruction of IA-32 processor multiplication.

14.2 LAB EXPERIMENT SCHEDULE

Exp. No Date Experiments Roll No's

1

P1 15R21A0 5F3,5F8,5G3,5G8,5H3,5H8P2 5F4,5F9,5G4,5G9,5H4,5H9P3 5F5,5G0,5G5,5H0,5H5,5J0P4 5F6,5G1,5G6,5H1,5H6P5 5F7,5G2,5G7,5H2,5H7

2

P1 5F4,5F9,5G4,5G9,5H4,5H9P2 5F5,5G0,5G5,5H0,5H5,5J0P3 5F6,5G1,5G6,5H1,5H6P4 5F7,5G2,5G7,5H2,5H7P5 15R21A0 5F3,5F8,5G3,5G8,5H3,5H8

3

P1 5F5,5G0,5G5,5H0,5H5,5J0P2 5F6,5G1,5G6,5H1,5H6P3 5F7,5G2,5G7,5H2,5H7P4 15R21A0 5F3,5F8,5G3,5G8,5H3,5H8P5 5F4,5F9,5G4,5G9,5H4,5H9

4

P1 5F6,5G1,5G6,5H1,5H6P2 5F7,5G2,5G7,5H2,5H7P3 15R21A0 5F3,5F8,5G3,5G8,5H3,5H8P4 5F4,5F9,5G4,5G9,5H4,5H9P5 5F5,5G0,5G5,5H0,5H5,5J0

5

P1 5F7,5G2,5G7,5H2,5H7P2 15R21A0 5F3,5F8,5G3,5G8,5H3,5H8P3 5F4,5F9,5G4,5G9,5H4,5H9P4 5F5,5G0,5G5,5H0,5H5,5J0P5 5F6,5G1,5G6,5H1,5H6

6P1 15R21A0 5F3,5F8,5G3,5G8,5H3,5H8P2 5F4,5F9,5G4,5G9,5H4,5H9P3 5F5,5G0,5G5,5H0,5H5,5J0

MLR Institute of Technology, Dundigal, Hyd-500043 Page 133

Page 134: 9.12TUTORIALQUESTIONS - MLR Institute of Web viewDepartment of CSE. Department of CSE. MLR Institute of Technology, Dundigal, Hyd-500043Page 2. MLR Institute of Technology, Dundigal,

Department of CSE

P4 5F6,5G1,5G6,5H1,5H6P5 5F7,5G2,5G7,5H2,5H7

7

P1 5F4,5F9,5G4,5G9,5H4,5H9P2 5F5,5G0,5G5,5H0,5H5,5J0P3 5F6,5G1,5G6,5H1,5H6P4 5F7,5G2,5G7,5H2,5H7P5 15R21A0 5F3,5F8,5G3,5G8,5H3,5H8

8

P1 5F5,5G0,5G5,5H0,5H5,5J0P2 5F6,5G1,5G6,5H1,5H6P3 5F7,5G2,5G7,5H2,5H7P4 15R21A0 5F3,5F8,5G3,5G8,5H3,5H8P5 5F4,5F9,5G4,5G9,5H4,5H9

9

P1 5F5,5G0,5G5,5H0,5H5,5J0P2 5F6,5G1,5G6,5H1,5H6P3 5F7,5G2,5G7,5H2,5H7P4 15R21A0 5F3,5F8,5G3,5G8,5H3,5H8P5 5F4,5F9,5G4,5G9,5H4,5H9

10

P1 5F6,5G1,5G6,5H1,5H6P2 5F7,5G2,5G7,5H2,5H7P3 15R21A0 5F3,5F8,5G3,5G8,5H3,5H8P4 5F4,5F9,5G4,5G9,5H4,5H9P5 5F5,5G0,5G5,5H0,5H5,5J0

11

P1 15R21A0 5F3,5F8,5G3,5G8,5H3,5H8P2 5F4,5F9,5G4,5G9,5H4,5H9P3 5F5,5G0,5G5,5H0,5H5,5J0P4 5F6,5G1,5G6,5H1,5H6P5 5F7,5G2,5G7,5H2,5H7

12

P1 5F4,5F9,5G4,5G9,5H4,5H9P2 5F5,5G0,5G5,5H0,5H5,5J0P3 5F6,5G1,5G6,5H1,5H6P4 5F7,5G2,5G7,5H2,5H7P5 15R21A0 5F3,5F8,5G3,5G8,5H3,5H8

MLR Institute of Technology, Dundigal, Hyd-500043 Page 134

Page 135: 9.12TUTORIALQUESTIONS - MLR Institute of Web viewDepartment of CSE. Department of CSE. MLR Institute of Technology, Dundigal, Hyd-500043Page 2. MLR Institute of Technology, Dundigal,

Department of CSE

15. ELECTRONIC DEVICES AND DIGITAL CIRCUITS LAB

15.1 SYLLABUS

PART - AANALOG DEVICES AND CIRCUITS1. Characteristics of PN Junction diode2. Characteristics of Zener diode3. Ripple Factor and Load Regulations of Half-wave Rectifier with and without filters4. Ripple Factor and Load Regulations of Full-wave Rectifier with and without filters5. Input and Output characteristics of Transistor in Common Emitter configuration6. Drain and Transfer Characteristics of Junction Field Effect Transistor (JFET)7. Gain and Frequency response of Common Emitter Amplifier8. Gain and Frequency response of Feedback Amplifier (Voltage series or current series)9. Heartley and Colpitts Oscillator10. RC phase shift Oscillator

PART - BDIGITAL CIRCUITS1. Realization of Logic gates using discrete components2. Binary Adders and Sub tractors3. Comparators4. Multiplexers5. Decoders6. Flip-Flops7. Counters8. Shift Registers

15.2 LAB EXPERIMENT SCHEDULE

Exp. No Date Experiments Roll No's

1

P1 15R21A0 5F3,5F8,5G3,5G8,5H3,5H8P2 5F4,5F9,5G4,5G9,5H4,5H9P3 5F5,5G0,5G5,5H0,5H5,5J0P4 5F6,5G1,5G6,5H1,5H6P5 5F7,5G2,5G7,5H2,5H7

2

P1 5F4,5F9,5G4,5G9,5H4,5H9P2 5F5,5G0,5G5,5H0,5H5,5J0P3 5F6,5G1,5G6,5H1,5H6P4 5F7,5G2,5G7,5H2,5H7P5 15R21A0 5F3,5F8,5G3,5G8,5H3,5H8

3

P1 5F5,5G0,5G5,5H0,5H5,5J0P2 5F6,5G1,5G6,5H1,5H6P3 5F7,5G2,5G7,5H2,5H7P4 15R21A0 5F3,5F8,5G3,5G8,5H3,5H8P5 5F4,5F9,5G4,5G9,5H4,5H9

4P1 5F6,5G1,5G6,5H1,5H6P2 5F7,5G2,5G7,5H2,5H7

MLR Institute of Technology, Dundigal, Hyd-500043 Page 135

Page 136: 9.12TUTORIALQUESTIONS - MLR Institute of Web viewDepartment of CSE. Department of CSE. MLR Institute of Technology, Dundigal, Hyd-500043Page 2. MLR Institute of Technology, Dundigal,

Department of CSE

P3 15R21A0 5F3,5F8,5G3,5G8,5H3,5H8P4 5F4,5F9,5G4,5G9,5H4,5H9P5 5F5,5G0,5G5,5H0,5H5,5J0

5

P1 5F7,5G2,5G7,5H2,5H7P2 15R21A0 5F3,5F8,5G3,5G8,5H3,5H8P3 5F4,5F9,5G4,5G9,5H4,5H9P4 5F5,5G0,5G5,5H0,5H5,5J0P5 5F6,5G1,5G6,5H1,5H6

6

P1 15R21A0 5F3,5F8,5G3,5G8,5H3,5H8P2 5F4,5F9,5G4,5G9,5H4,5H9P3 5F5,5G0,5G5,5H0,5H5,5J0P4 5F6,5G1,5G6,5H1,5H6P5 5F7,5G2,5G7,5H2,5H7

7

P1 5F4,5F9,5G4,5G9,5H4,5H9P2 5F5,5G0,5G5,5H0,5H5,5J0P3 5F6,5G1,5G6,5H1,5H6P4 5F7,5G2,5G7,5H2,5H7P5 15R21A0 5F3,5F8,5G3,5G8,5H3,5H8

8

P1 5F5,5G0,5G5,5H0,5H5,5J0P2 5F6,5G1,5G6,5H1,5H6P3 5F7,5G2,5G7,5H2,5H7P4 15R21A0 5F3,5F8,5G3,5G8,5H3,5H8P5 5F4,5F9,5G4,5G9,5H4,5H9

9

P1 5F5,5G0,5G5,5H0,5H5,5J0P2 5F6,5G1,5G6,5H1,5H6P3 5F7,5G2,5G7,5H2,5H7P4 15R21A0 5F3,5F8,5G3,5G8,5H3,5H8P5 5F4,5F9,5G4,5G9,5H4,5H9

10

P1 5F6,5G1,5G6,5H1,5H6P2 5F7,5G2,5G7,5H2,5H7P3 15R21A0 5F3,5F8,5G3,5G8,5H3,5H8P4 5F4,5F9,5G4,5G9,5H4,5H9P5 5F5,5G0,5G5,5H0,5H5,5J0

11P1 15R21A0 5F3,5F8,5G3,5G8,5H3,5H8P2 5F4,5F9,5G4,5G9,5H4,5H9P3 5F5,5G0,5G5,5H0,5H5,5J0P4 5F6,5G1,5G6,5H1,5H6P5 5F7,5G2,5G7,5H2,5H7

12

P1 5F4,5F9,5G4,5G9,5H4,5H9P2 5F5,5G0,5G5,5H0,5H5,5J0P3 5F6,5G1,5G6,5H1,5H6P4 5F7,5G2,5G7,5H2,5H7P5 15R21A0 5F3,5F8,5G3,5G8,5H3,5H8

MLR Institute of Technology, Dundigal, Hyd-500043 Page 136

Page 137: 9.12TUTORIALQUESTIONS - MLR Institute of Web viewDepartment of CSE. Department of CSE. MLR Institute of Technology, Dundigal, Hyd-500043Page 2. MLR Institute of Technology, Dundigal,

Department of CSE

16. OBJECT ORIENTED PROGRAMMING USING C++ LAB (A10510)

16.1 SYLLABUS

WEEK 1 1. Write C++ Program to read student marks and display average.2. Write C++ Program to find volume of a cube using Inline functions.3. Write C++ Program to swap two numbers using call by reference

WEEK 21. Write C++ Program to access member function of other class using Friend function2. Write C++ Program to two complex numbers using Operator Overloading3. Write C++ Program Using Function Overloading to add two integers, floating point numbers and

complex numbers.

WEEK 31. Write C++ program to create object of a class using copy constructor2. Write C++ Program to call Virtual function.3. Write C++ program to de allocate memory using destructors.

WEEK 41. Write a C++ program to implementSingle Inheritance 2. Write a C++ program to implement Multiple Inheritance

WEEK 5Write a C++ Program to print the string length and reverse the string

WEEK 6 Write a C++ Program using pointers to access array of integers

WEEK 7 Write a C++ Program to create a structure to store student details and access using pointers

WEEK 8 Write C++ program to implement generic stack and its operations

WEEK 9 Write C++ program to create a file and search for particular record and display it

WEEK 10 Write C++ program to create function templates and overload function templates

WEEK 11 Write a C++ Program to demonstrate I/O streams and functions. WEEK 12 Write a C++ Program to create user defined exception class to handle “Not a Number” exception

TEXT BOOKS:1. Data structures, Algorithms and Applications in C++, S.Sahni, University Press (India) Pvt.Ltd,

2nd edition, Universities Press Orient Longman Pvt. Ltd.

REFERENCES:1. Data structures and Algorithms in C++, Michael T.Goodrich, R.Tamassia2. Data structures and Algorithm Analysis in C++, Mark Allen Weiss, Pearson Education. Ltd

Second Edition.3. Data structures using C and C++, Langsam, Augenstein and Tanenbaum, PHI. 4. Problem solving with C++, The OOP, Fourth edition, W.Savitch, Pearson Education. 5. Data Structures and Algorithms Using C++, Ananda Rao Akepogu, Radhika Raju Palagiri

MLR Institute of Technology, Dundigal, Hyd-500043 Page 137

Page 138: 9.12TUTORIALQUESTIONS - MLR Institute of Web viewDepartment of CSE. Department of CSE. MLR Institute of Technology, Dundigal, Hyd-500043Page 2. MLR Institute of Technology, Dundigal,

Department of CSE

16.2 LAB EXPERIMENT SCHEDULE

SNO WEEK NO NAME OF THE EXPERIMENT DATE

PLANNEDDATE

CODUCTED

1 1

1. WriteC++ Program to read student marks and display average.

2. WriteC++ Program to find volume of a cube using Inline functions.

3.Write C++ Program to swap two numbers using call by reference

2 2

1.Write C++ Program to access member function of other class using Friend function

2.Write C++ Program to two complex numbers using Operator Overloading

3.Write C++ Program Using Function Overloading to add two integers, floating point numbers and complex numbers.

3 3

1.Write C++ program to create object of a class using copy constructor

2. Write C++ Program to call Virtual function.3.Write C++ program to de allocate memory using

destructors.

4 4 1.Write a C++ program to implementSingle Inheritance2. Write a C++ program to implement Multiple Inheritance

5 5 Write a C++ Program to print the string length and reverse the string

6 6 Write a C++ Program using pointers to access array of integers

7 7 Write a C++ Program to create a structure to store student details and access using pointers

8 8 Write C++ program to implement generic stack and its operations

9 9 Write C++ program to create a file and search for particular record and display it

10 10 Write C++ program to create function templates and overload function templates

11 11 Write a C++ Program to demonstrate I/O streams and functions

12 12 Write a C++ Program to create user defined exception class to handle “Not a Number” exception

MLR Institute of Technology, Dundigal, Hyd-500043 Page 138