SlideShare a Scribd company logo
1 of 1
Name of the Student ………… University Roll No. ……….
Subject: Design and Analysis of Algorithm Subject Code: KAC010 Max Marks: 30
Semester: 3rd Branch/Section: MCA Time: 1Hour
INSTRUCTIONS :
1. Attempt all sections
2. No “B” Answer Sheet will be provided
3. Student will not be allowed to leave the examination Hall before one hour
Q. 1 Attempt all. (4 x 2.5 = 10)
(a) Write any two differences between greedy and dynamic programming approach.
(b) How Binary Search Tree is constructed using J, R, D, T, G, E, A, M, H, F, Q, U, B.
(c) Discuss Knapsack problem as Dynamic programming approach or greedy approach.
(d) Write a recursive function for activity selection problem.
Q.2 Attempt each part. (2 x 5 = 10)
(a) Given two sequences X = <x1, x2….xn> and Y = <y1,y2,…..yn>. Write the algorithm for
longest common Subsequence (LCS) of x and y using Dynamic Programming. Also write a
subroutine to print the longest common sub sequence (LCS).
(b) Let n =4 (P1,P2,P3,P4)= (100,10,15,27) and (d1,d2,d3,d4)=(2,1,2,1) where pi are profits
on processes or job and di are deadlines of completion . Find the Optimal schedule.
Q.3 Attempt the following. (2 x 5= 10)
a) Discuss matrix chain multiplication with reference to dynamic Programming technique
and also apply on the following array
b) Write an algorithm to insert an element in BST and also explain it with an example.
30 1 40 10 25
DIT UNIVERSITY, DEHRADUN
SECOND MID-TERM EXAMINATION (ODD SEMESTER - 2015)
(MCA 2nd Year Students only)

More Related Content

What's hot

Edm2014 investigating automated student modeling in a java mooc
Edm2014 investigating automated student modeling in a java moocEdm2014 investigating automated student modeling in a java mooc
Edm2014 investigating automated student modeling in a java moocRoya Hosseini
 
Software Testing (Revised Syllabus) [QP / April - 2015]
Software Testing (Revised Syllabus) [QP / April - 2015]Software Testing (Revised Syllabus) [QP / April - 2015]
Software Testing (Revised Syllabus) [QP / April - 2015]Mumbai B.Sc.IT Study
 
Jindřich Libovický - 2017 - Attention Strategies for Multi-Source Sequence-...
Jindřich Libovický - 2017 - Attention Strategies for Multi-Source Sequence-...Jindřich Libovický - 2017 - Attention Strategies for Multi-Source Sequence-...
Jindřich Libovický - 2017 - Attention Strategies for Multi-Source Sequence-...Association for Computational Linguistics
 
Divide&Conquer & Dynamic Programming
Divide&Conquer & Dynamic ProgrammingDivide&Conquer & Dynamic Programming
Divide&Conquer & Dynamic ProgrammingGuillaume Guérard
 
Week4 practice
Week4 practiceWeek4 practice
Week4 practice기식 정
 
Computer Science XII - Hissan 2078
Computer Science XII - Hissan 2078Computer Science XII - Hissan 2078
Computer Science XII - Hissan 2078YEP Nepal
 
Design and analysis of algorithms - Abstract View
Design and analysis of algorithms - Abstract ViewDesign and analysis of algorithms - Abstract View
Design and analysis of algorithms - Abstract ViewWaqas Nawaz
 
Analysis of algorithms
Analysis of algorithmsAnalysis of algorithms
Analysis of algorithmsGanesh Solanke
 
20181204i mlse discussions
20181204i mlse discussions20181204i mlse discussions
20181204i mlse discussionsHiroshi Maruyama
 
PGCET Computer science 2017 question paper
PGCET Computer science 2017 question paperPGCET Computer science 2017 question paper
PGCET Computer science 2017 question paperEneutron
 
Pgcet Computer Science 2015 question paper
Pgcet Computer Science 2015 question paperPgcet Computer Science 2015 question paper
Pgcet Computer Science 2015 question paperEneutron
 
Cs6660 compiler design may june 2017 answer key
Cs6660 compiler design may june 2017  answer keyCs6660 compiler design may june 2017  answer key
Cs6660 compiler design may june 2017 answer keyappasami
 
connecting discrete mathematics and software engineering
connecting discrete mathematics and software engineeringconnecting discrete mathematics and software engineering
connecting discrete mathematics and software engineeringRam Kumar K R
 
TIM: Large-scale Energy Forecasting in Julia
TIM: Large-scale Energy Forecasting in JuliaTIM: Large-scale Energy Forecasting in Julia
TIM: Large-scale Energy Forecasting in JuliaGapData Institute
 

What's hot (20)

Cad for vlsi design june2013 (1)
Cad for vlsi design june2013 (1)Cad for vlsi design june2013 (1)
Cad for vlsi design june2013 (1)
 
Mca 104
Mca 104Mca 104
Mca 104
 
Edm2014 investigating automated student modeling in a java mooc
Edm2014 investigating automated student modeling in a java moocEdm2014 investigating automated student modeling in a java mooc
Edm2014 investigating automated student modeling in a java mooc
 
Oop december 2018
Oop december 2018Oop december 2018
Oop december 2018
 
Bba 406 2015
Bba 406 2015Bba 406 2015
Bba 406 2015
 
Software Testing (Revised Syllabus) [QP / April - 2015]
Software Testing (Revised Syllabus) [QP / April - 2015]Software Testing (Revised Syllabus) [QP / April - 2015]
Software Testing (Revised Syllabus) [QP / April - 2015]
 
Jindřich Libovický - 2017 - Attention Strategies for Multi-Source Sequence-...
Jindřich Libovický - 2017 - Attention Strategies for Multi-Source Sequence-...Jindřich Libovický - 2017 - Attention Strategies for Multi-Source Sequence-...
Jindřich Libovický - 2017 - Attention Strategies for Multi-Source Sequence-...
 
Divide&Conquer & Dynamic Programming
Divide&Conquer & Dynamic ProgrammingDivide&Conquer & Dynamic Programming
Divide&Conquer & Dynamic Programming
 
Week4 practice
Week4 practiceWeek4 practice
Week4 practice
 
Computer Science XII - Hissan 2078
Computer Science XII - Hissan 2078Computer Science XII - Hissan 2078
Computer Science XII - Hissan 2078
 
Design and analysis of algorithms - Abstract View
Design and analysis of algorithms - Abstract ViewDesign and analysis of algorithms - Abstract View
Design and analysis of algorithms - Abstract View
 
Analysis of algorithms
Analysis of algorithmsAnalysis of algorithms
Analysis of algorithms
 
20181204i mlse discussions
20181204i mlse discussions20181204i mlse discussions
20181204i mlse discussions
 
PGCET Computer science 2017 question paper
PGCET Computer science 2017 question paperPGCET Computer science 2017 question paper
PGCET Computer science 2017 question paper
 
Analysis of algo
Analysis of algoAnalysis of algo
Analysis of algo
 
Parallel algorithm in linear algebra
Parallel algorithm in linear algebraParallel algorithm in linear algebra
Parallel algorithm in linear algebra
 
Pgcet Computer Science 2015 question paper
Pgcet Computer Science 2015 question paperPgcet Computer Science 2015 question paper
Pgcet Computer Science 2015 question paper
 
Cs6660 compiler design may june 2017 answer key
Cs6660 compiler design may june 2017  answer keyCs6660 compiler design may june 2017  answer key
Cs6660 compiler design may june 2017 answer key
 
connecting discrete mathematics and software engineering
connecting discrete mathematics and software engineeringconnecting discrete mathematics and software engineering
connecting discrete mathematics and software engineering
 
TIM: Large-scale Energy Forecasting in Julia
TIM: Large-scale Energy Forecasting in JuliaTIM: Large-scale Energy Forecasting in Julia
TIM: Large-scale Energy Forecasting in Julia
 

Similar to 2nd mid term daa paper

GSP 125 Enhance teaching/tutorialrank.com
 GSP 125 Enhance teaching/tutorialrank.com GSP 125 Enhance teaching/tutorialrank.com
GSP 125 Enhance teaching/tutorialrank.comjonhson300
 
GSP 125 Effective Communication/tutorialrank.com
 GSP 125 Effective Communication/tutorialrank.com GSP 125 Effective Communication/tutorialrank.com
GSP 125 Effective Communication/tutorialrank.comjonhson282
 
GSP 125 RANK Education for Service--gsp125rank.com
GSP 125 RANK  Education for Service--gsp125rank.comGSP 125 RANK  Education for Service--gsp125rank.com
GSP 125 RANK Education for Service--gsp125rank.comclaric25
 
GSP 125 Exceptional Education - snaptutorial.com
GSP 125 Exceptional Education - snaptutorial.comGSP 125 Exceptional Education - snaptutorial.com
GSP 125 Exceptional Education - snaptutorial.comdonaldzs162
 
GSP 125 Education Specialist / snaptutorial.com
  GSP 125 Education Specialist / snaptutorial.com  GSP 125 Education Specialist / snaptutorial.com
GSP 125 Education Specialist / snaptutorial.comstevesonz146
 
GSP 125 Technology levels--snaptutorial.com
GSP 125 Technology levels--snaptutorial.comGSP 125 Technology levels--snaptutorial.com
GSP 125 Technology levels--snaptutorial.comsholingarjosh136
 
Gsp 125 Massive Success / snaptutorial.com
Gsp 125  Massive Success / snaptutorial.comGsp 125  Massive Success / snaptutorial.com
Gsp 125 Massive Success / snaptutorial.comNorrisMistryzo
 
Gsp 125 Enthusiastic Study / snaptutorial.com
Gsp 125 Enthusiastic Study / snaptutorial.comGsp 125 Enthusiastic Study / snaptutorial.com
Gsp 125 Enthusiastic Study / snaptutorial.comStephenson101
 
Gsp 125 Education Organization -- snaptutorial.com
Gsp 125   Education Organization -- snaptutorial.comGsp 125   Education Organization -- snaptutorial.com
Gsp 125 Education Organization -- snaptutorial.comDavisMurphyB85
 
GSP 125 Perfect Education/newtonhelp.com
GSP 125 Perfect Education/newtonhelp.comGSP 125 Perfect Education/newtonhelp.com
GSP 125 Perfect Education/newtonhelp.combellflower169
 
Gsp 125 Future Our Mission/newtonhelp.com
Gsp 125 Future Our Mission/newtonhelp.comGsp 125 Future Our Mission/newtonhelp.com
Gsp 125 Future Our Mission/newtonhelp.comamaranthbeg8
 
GSP 125 Become Exceptional/newtonhelp.com
GSP 125 Become Exceptional/newtonhelp.comGSP 125 Become Exceptional/newtonhelp.com
GSP 125 Become Exceptional/newtonhelp.combellflower148
 
GSP 125 Doing by learn/newtonhelp.com
GSP 125 Doing by learn/newtonhelp.comGSP 125 Doing by learn/newtonhelp.com
GSP 125 Doing by learn/newtonhelp.combellflower126
 
GSP 125 Enhance teaching - snaptutorial.com
GSP 125   Enhance teaching - snaptutorial.comGSP 125   Enhance teaching - snaptutorial.com
GSP 125 Enhance teaching - snaptutorial.comDavisMurphyA81
 
Sp 1418794917
Sp 1418794917Sp 1418794917
Sp 1418794917lakshmi r
 
GSP 125 Final Exam Guide
GSP 125 Final Exam GuideGSP 125 Final Exam Guide
GSP 125 Final Exam Guidemonsterr20
 
GSP 125 Entire Course NEW
GSP 125 Entire Course NEWGSP 125 Entire Course NEW
GSP 125 Entire Course NEWshyamuopten
 

Similar to 2nd mid term daa paper (20)

GSP 125 Enhance teaching/tutorialrank.com
 GSP 125 Enhance teaching/tutorialrank.com GSP 125 Enhance teaching/tutorialrank.com
GSP 125 Enhance teaching/tutorialrank.com
 
GSP 125 Effective Communication/tutorialrank.com
 GSP 125 Effective Communication/tutorialrank.com GSP 125 Effective Communication/tutorialrank.com
GSP 125 Effective Communication/tutorialrank.com
 
Gate-Cs 1995
Gate-Cs 1995Gate-Cs 1995
Gate-Cs 1995
 
GSP 125 RANK Education for Service--gsp125rank.com
GSP 125 RANK  Education for Service--gsp125rank.comGSP 125 RANK  Education for Service--gsp125rank.com
GSP 125 RANK Education for Service--gsp125rank.com
 
GSP 125 Exceptional Education - snaptutorial.com
GSP 125 Exceptional Education - snaptutorial.comGSP 125 Exceptional Education - snaptutorial.com
GSP 125 Exceptional Education - snaptutorial.com
 
GSP 125 Education Specialist / snaptutorial.com
  GSP 125 Education Specialist / snaptutorial.com  GSP 125 Education Specialist / snaptutorial.com
GSP 125 Education Specialist / snaptutorial.com
 
GSP 125 Technology levels--snaptutorial.com
GSP 125 Technology levels--snaptutorial.comGSP 125 Technology levels--snaptutorial.com
GSP 125 Technology levels--snaptutorial.com
 
Gsp 125 Massive Success / snaptutorial.com
Gsp 125  Massive Success / snaptutorial.comGsp 125  Massive Success / snaptutorial.com
Gsp 125 Massive Success / snaptutorial.com
 
Gsp 125 Enthusiastic Study / snaptutorial.com
Gsp 125 Enthusiastic Study / snaptutorial.comGsp 125 Enthusiastic Study / snaptutorial.com
Gsp 125 Enthusiastic Study / snaptutorial.com
 
Gsp 125 Education Organization -- snaptutorial.com
Gsp 125   Education Organization -- snaptutorial.comGsp 125   Education Organization -- snaptutorial.com
Gsp 125 Education Organization -- snaptutorial.com
 
GSP 125 Perfect Education/newtonhelp.com
GSP 125 Perfect Education/newtonhelp.comGSP 125 Perfect Education/newtonhelp.com
GSP 125 Perfect Education/newtonhelp.com
 
Gsp 125 Future Our Mission/newtonhelp.com
Gsp 125 Future Our Mission/newtonhelp.comGsp 125 Future Our Mission/newtonhelp.com
Gsp 125 Future Our Mission/newtonhelp.com
 
GSP 125 Become Exceptional/newtonhelp.com
GSP 125 Become Exceptional/newtonhelp.comGSP 125 Become Exceptional/newtonhelp.com
GSP 125 Become Exceptional/newtonhelp.com
 
GSP 125 Doing by learn/newtonhelp.com
GSP 125 Doing by learn/newtonhelp.comGSP 125 Doing by learn/newtonhelp.com
GSP 125 Doing by learn/newtonhelp.com
 
GSP 125 Enhance teaching - snaptutorial.com
GSP 125   Enhance teaching - snaptutorial.comGSP 125   Enhance teaching - snaptutorial.com
GSP 125 Enhance teaching - snaptutorial.com
 
Sp 1418794917
Sp 1418794917Sp 1418794917
Sp 1418794917
 
Gsp 125 final exam guide
Gsp 125 final exam guideGsp 125 final exam guide
Gsp 125 final exam guide
 
GSP 125 Final Exam Guide
GSP 125 Final Exam GuideGSP 125 Final Exam Guide
GSP 125 Final Exam Guide
 
Cse 3rd yr (se)
Cse 3rd yr (se)Cse 3rd yr (se)
Cse 3rd yr (se)
 
GSP 125 Entire Course NEW
GSP 125 Entire Course NEWGSP 125 Entire Course NEW
GSP 125 Entire Course NEW
 

Recently uploaded

UNIT-III FMM. DIMENSIONAL ANALYSIS
UNIT-III FMM.        DIMENSIONAL ANALYSISUNIT-III FMM.        DIMENSIONAL ANALYSIS
UNIT-III FMM. DIMENSIONAL ANALYSISrknatarajan
 
Model Call Girl in Narela Delhi reach out to us at 🔝8264348440🔝
Model Call Girl in Narela Delhi reach out to us at 🔝8264348440🔝Model Call Girl in Narela Delhi reach out to us at 🔝8264348440🔝
Model Call Girl in Narela Delhi reach out to us at 🔝8264348440🔝soniya singh
 
Decoding Kotlin - Your guide to solving the mysterious in Kotlin.pptx
Decoding Kotlin - Your guide to solving the mysterious in Kotlin.pptxDecoding Kotlin - Your guide to solving the mysterious in Kotlin.pptx
Decoding Kotlin - Your guide to solving the mysterious in Kotlin.pptxJoão Esperancinha
 
the ladakh protest in leh ladakh 2024 sonam wangchuk.pptx
the ladakh protest in leh ladakh 2024 sonam wangchuk.pptxthe ladakh protest in leh ladakh 2024 sonam wangchuk.pptx
the ladakh protest in leh ladakh 2024 sonam wangchuk.pptxhumanexperienceaaa
 
Introduction to Multiple Access Protocol.pptx
Introduction to Multiple Access Protocol.pptxIntroduction to Multiple Access Protocol.pptx
Introduction to Multiple Access Protocol.pptxupamatechverse
 
(SHREYA) Chakan Call Girls Just Call 7001035870 [ Cash on Delivery ] Pune Esc...
(SHREYA) Chakan Call Girls Just Call 7001035870 [ Cash on Delivery ] Pune Esc...(SHREYA) Chakan Call Girls Just Call 7001035870 [ Cash on Delivery ] Pune Esc...
(SHREYA) Chakan Call Girls Just Call 7001035870 [ Cash on Delivery ] Pune Esc...ranjana rawat
 
HARDNESS, FRACTURE TOUGHNESS AND STRENGTH OF CERAMICS
HARDNESS, FRACTURE TOUGHNESS AND STRENGTH OF CERAMICSHARDNESS, FRACTURE TOUGHNESS AND STRENGTH OF CERAMICS
HARDNESS, FRACTURE TOUGHNESS AND STRENGTH OF CERAMICSRajkumarAkumalla
 
APPLICATIONS-AC/DC DRIVES-OPERATING CHARACTERISTICS
APPLICATIONS-AC/DC DRIVES-OPERATING CHARACTERISTICSAPPLICATIONS-AC/DC DRIVES-OPERATING CHARACTERISTICS
APPLICATIONS-AC/DC DRIVES-OPERATING CHARACTERISTICSKurinjimalarL3
 
High Profile Call Girls Nagpur Meera Call 7001035870 Meet With Nagpur Escorts
High Profile Call Girls Nagpur Meera Call 7001035870 Meet With Nagpur EscortsHigh Profile Call Girls Nagpur Meera Call 7001035870 Meet With Nagpur Escorts
High Profile Call Girls Nagpur Meera Call 7001035870 Meet With Nagpur EscortsCall Girls in Nagpur High Profile
 
Call Girls in Nagpur Suman Call 7001035870 Meet With Nagpur Escorts
Call Girls in Nagpur Suman Call 7001035870 Meet With Nagpur EscortsCall Girls in Nagpur Suman Call 7001035870 Meet With Nagpur Escorts
Call Girls in Nagpur Suman Call 7001035870 Meet With Nagpur EscortsCall Girls in Nagpur High Profile
 
Introduction and different types of Ethernet.pptx
Introduction and different types of Ethernet.pptxIntroduction and different types of Ethernet.pptx
Introduction and different types of Ethernet.pptxupamatechverse
 
MANUFACTURING PROCESS-II UNIT-2 LATHE MACHINE
MANUFACTURING PROCESS-II UNIT-2 LATHE MACHINEMANUFACTURING PROCESS-II UNIT-2 LATHE MACHINE
MANUFACTURING PROCESS-II UNIT-2 LATHE MACHINESIVASHANKAR N
 
Processing & Properties of Floor and Wall Tiles.pptx
Processing & Properties of Floor and Wall Tiles.pptxProcessing & Properties of Floor and Wall Tiles.pptx
Processing & Properties of Floor and Wall Tiles.pptxpranjaldaimarysona
 
(PRIYA) Rajgurunagar Call Girls Just Call 7001035870 [ Cash on Delivery ] Pun...
(PRIYA) Rajgurunagar Call Girls Just Call 7001035870 [ Cash on Delivery ] Pun...(PRIYA) Rajgurunagar Call Girls Just Call 7001035870 [ Cash on Delivery ] Pun...
(PRIYA) Rajgurunagar Call Girls Just Call 7001035870 [ Cash on Delivery ] Pun...ranjana rawat
 
OSVC_Meta-Data based Simulation Automation to overcome Verification Challenge...
OSVC_Meta-Data based Simulation Automation to overcome Verification Challenge...OSVC_Meta-Data based Simulation Automation to overcome Verification Challenge...
OSVC_Meta-Data based Simulation Automation to overcome Verification Challenge...Soham Mondal
 
Call Girls Service Nagpur Tanvi Call 7001035870 Meet With Nagpur Escorts
Call Girls Service Nagpur Tanvi Call 7001035870 Meet With Nagpur EscortsCall Girls Service Nagpur Tanvi Call 7001035870 Meet With Nagpur Escorts
Call Girls Service Nagpur Tanvi Call 7001035870 Meet With Nagpur EscortsCall Girls in Nagpur High Profile
 
College Call Girls Nashik Nehal 7001305949 Independent Escort Service Nashik
College Call Girls Nashik Nehal 7001305949 Independent Escort Service NashikCollege Call Girls Nashik Nehal 7001305949 Independent Escort Service Nashik
College Call Girls Nashik Nehal 7001305949 Independent Escort Service NashikCall Girls in Nagpur High Profile
 
Call for Papers - African Journal of Biological Sciences, E-ISSN: 2663-2187, ...
Call for Papers - African Journal of Biological Sciences, E-ISSN: 2663-2187, ...Call for Papers - African Journal of Biological Sciences, E-ISSN: 2663-2187, ...
Call for Papers - African Journal of Biological Sciences, E-ISSN: 2663-2187, ...Christo Ananth
 

Recently uploaded (20)

Call Us -/9953056974- Call Girls In Vikaspuri-/- Delhi NCR
Call Us -/9953056974- Call Girls In Vikaspuri-/- Delhi NCRCall Us -/9953056974- Call Girls In Vikaspuri-/- Delhi NCR
Call Us -/9953056974- Call Girls In Vikaspuri-/- Delhi NCR
 
UNIT-III FMM. DIMENSIONAL ANALYSIS
UNIT-III FMM.        DIMENSIONAL ANALYSISUNIT-III FMM.        DIMENSIONAL ANALYSIS
UNIT-III FMM. DIMENSIONAL ANALYSIS
 
Model Call Girl in Narela Delhi reach out to us at 🔝8264348440🔝
Model Call Girl in Narela Delhi reach out to us at 🔝8264348440🔝Model Call Girl in Narela Delhi reach out to us at 🔝8264348440🔝
Model Call Girl in Narela Delhi reach out to us at 🔝8264348440🔝
 
Decoding Kotlin - Your guide to solving the mysterious in Kotlin.pptx
Decoding Kotlin - Your guide to solving the mysterious in Kotlin.pptxDecoding Kotlin - Your guide to solving the mysterious in Kotlin.pptx
Decoding Kotlin - Your guide to solving the mysterious in Kotlin.pptx
 
the ladakh protest in leh ladakh 2024 sonam wangchuk.pptx
the ladakh protest in leh ladakh 2024 sonam wangchuk.pptxthe ladakh protest in leh ladakh 2024 sonam wangchuk.pptx
the ladakh protest in leh ladakh 2024 sonam wangchuk.pptx
 
★ CALL US 9953330565 ( HOT Young Call Girls In Badarpur delhi NCR
★ CALL US 9953330565 ( HOT Young Call Girls In Badarpur delhi NCR★ CALL US 9953330565 ( HOT Young Call Girls In Badarpur delhi NCR
★ CALL US 9953330565 ( HOT Young Call Girls In Badarpur delhi NCR
 
Introduction to Multiple Access Protocol.pptx
Introduction to Multiple Access Protocol.pptxIntroduction to Multiple Access Protocol.pptx
Introduction to Multiple Access Protocol.pptx
 
(SHREYA) Chakan Call Girls Just Call 7001035870 [ Cash on Delivery ] Pune Esc...
(SHREYA) Chakan Call Girls Just Call 7001035870 [ Cash on Delivery ] Pune Esc...(SHREYA) Chakan Call Girls Just Call 7001035870 [ Cash on Delivery ] Pune Esc...
(SHREYA) Chakan Call Girls Just Call 7001035870 [ Cash on Delivery ] Pune Esc...
 
HARDNESS, FRACTURE TOUGHNESS AND STRENGTH OF CERAMICS
HARDNESS, FRACTURE TOUGHNESS AND STRENGTH OF CERAMICSHARDNESS, FRACTURE TOUGHNESS AND STRENGTH OF CERAMICS
HARDNESS, FRACTURE TOUGHNESS AND STRENGTH OF CERAMICS
 
APPLICATIONS-AC/DC DRIVES-OPERATING CHARACTERISTICS
APPLICATIONS-AC/DC DRIVES-OPERATING CHARACTERISTICSAPPLICATIONS-AC/DC DRIVES-OPERATING CHARACTERISTICS
APPLICATIONS-AC/DC DRIVES-OPERATING CHARACTERISTICS
 
High Profile Call Girls Nagpur Meera Call 7001035870 Meet With Nagpur Escorts
High Profile Call Girls Nagpur Meera Call 7001035870 Meet With Nagpur EscortsHigh Profile Call Girls Nagpur Meera Call 7001035870 Meet With Nagpur Escorts
High Profile Call Girls Nagpur Meera Call 7001035870 Meet With Nagpur Escorts
 
Call Girls in Nagpur Suman Call 7001035870 Meet With Nagpur Escorts
Call Girls in Nagpur Suman Call 7001035870 Meet With Nagpur EscortsCall Girls in Nagpur Suman Call 7001035870 Meet With Nagpur Escorts
Call Girls in Nagpur Suman Call 7001035870 Meet With Nagpur Escorts
 
Introduction and different types of Ethernet.pptx
Introduction and different types of Ethernet.pptxIntroduction and different types of Ethernet.pptx
Introduction and different types of Ethernet.pptx
 
MANUFACTURING PROCESS-II UNIT-2 LATHE MACHINE
MANUFACTURING PROCESS-II UNIT-2 LATHE MACHINEMANUFACTURING PROCESS-II UNIT-2 LATHE MACHINE
MANUFACTURING PROCESS-II UNIT-2 LATHE MACHINE
 
Processing & Properties of Floor and Wall Tiles.pptx
Processing & Properties of Floor and Wall Tiles.pptxProcessing & Properties of Floor and Wall Tiles.pptx
Processing & Properties of Floor and Wall Tiles.pptx
 
(PRIYA) Rajgurunagar Call Girls Just Call 7001035870 [ Cash on Delivery ] Pun...
(PRIYA) Rajgurunagar Call Girls Just Call 7001035870 [ Cash on Delivery ] Pun...(PRIYA) Rajgurunagar Call Girls Just Call 7001035870 [ Cash on Delivery ] Pun...
(PRIYA) Rajgurunagar Call Girls Just Call 7001035870 [ Cash on Delivery ] Pun...
 
OSVC_Meta-Data based Simulation Automation to overcome Verification Challenge...
OSVC_Meta-Data based Simulation Automation to overcome Verification Challenge...OSVC_Meta-Data based Simulation Automation to overcome Verification Challenge...
OSVC_Meta-Data based Simulation Automation to overcome Verification Challenge...
 
Call Girls Service Nagpur Tanvi Call 7001035870 Meet With Nagpur Escorts
Call Girls Service Nagpur Tanvi Call 7001035870 Meet With Nagpur EscortsCall Girls Service Nagpur Tanvi Call 7001035870 Meet With Nagpur Escorts
Call Girls Service Nagpur Tanvi Call 7001035870 Meet With Nagpur Escorts
 
College Call Girls Nashik Nehal 7001305949 Independent Escort Service Nashik
College Call Girls Nashik Nehal 7001305949 Independent Escort Service NashikCollege Call Girls Nashik Nehal 7001305949 Independent Escort Service Nashik
College Call Girls Nashik Nehal 7001305949 Independent Escort Service Nashik
 
Call for Papers - African Journal of Biological Sciences, E-ISSN: 2663-2187, ...
Call for Papers - African Journal of Biological Sciences, E-ISSN: 2663-2187, ...Call for Papers - African Journal of Biological Sciences, E-ISSN: 2663-2187, ...
Call for Papers - African Journal of Biological Sciences, E-ISSN: 2663-2187, ...
 

2nd mid term daa paper

  • 1. Name of the Student ………… University Roll No. ………. Subject: Design and Analysis of Algorithm Subject Code: KAC010 Max Marks: 30 Semester: 3rd Branch/Section: MCA Time: 1Hour INSTRUCTIONS : 1. Attempt all sections 2. No “B” Answer Sheet will be provided 3. Student will not be allowed to leave the examination Hall before one hour Q. 1 Attempt all. (4 x 2.5 = 10) (a) Write any two differences between greedy and dynamic programming approach. (b) How Binary Search Tree is constructed using J, R, D, T, G, E, A, M, H, F, Q, U, B. (c) Discuss Knapsack problem as Dynamic programming approach or greedy approach. (d) Write a recursive function for activity selection problem. Q.2 Attempt each part. (2 x 5 = 10) (a) Given two sequences X = <x1, x2….xn> and Y = <y1,y2,…..yn>. Write the algorithm for longest common Subsequence (LCS) of x and y using Dynamic Programming. Also write a subroutine to print the longest common sub sequence (LCS). (b) Let n =4 (P1,P2,P3,P4)= (100,10,15,27) and (d1,d2,d3,d4)=(2,1,2,1) where pi are profits on processes or job and di are deadlines of completion . Find the Optimal schedule. Q.3 Attempt the following. (2 x 5= 10) a) Discuss matrix chain multiplication with reference to dynamic Programming technique and also apply on the following array b) Write an algorithm to insert an element in BST and also explain it with an example. 30 1 40 10 25 DIT UNIVERSITY, DEHRADUN SECOND MID-TERM EXAMINATION (ODD SEMESTER - 2015) (MCA 2nd Year Students only)