Skip to content

Object Oriented Design

SWE · Final · Fall 24

This browser can’t show the PDF here

Open it, and your phone’s PDF viewer takes it, or download it.

Read the questions as text

Read off the PDF by AI, so it may have mistakes. The PDF is the original.

Daffodil International University Department of Software Engineering Faculty of Science & Information Technology Final Examination, Fall 2024 Course Code: SE 221; Course Title: Object Oriented Design Sections & Teachers: [40(A-C)]AG, [40(D-G)]MBH, [40(H-I)]DB Time: 1:30 Hrs Marks: 25 Answer ALL Questions [The figures in the right margin indicate the full marks and corresponding course outcomes. All portions of each question must be answered sequentially.] 1 a) Suppose you have to develop a Car booking System for an online platform. All bookings have attributes like a bookingID, customerName, destination, pickUpPoint and approximateCost. But only Premium users can instantly book a vehicle. The Diamond users can set the speed limit for the ride. In this system, one premium or Diamond user can book a vehicle for later which is not available for normal users and this type of booking will provide a discount of 20% from the current fare. Diamond users can play movies during the journey where premium users can play music only. Consider the above scenario and picturize a complete class diagram with standard notations. Please remember, you can not disclose the data of one end to another [Marks-10] | CLO-1 Level-2 2 a) In Q1, have you used any kind of Object oriented concept among the 4 pillars? Demonstrate the need of these concepts with some other code examples. [Marks-3] | CLO-3 Level-3 b) When can we use try, catch and finally blocks in JAVA? Examine with a proper scenario while creating an object. [Marks-2] | 3 a) [Figure: Class diagram showing Person interface, Address class, AttendanceSheet class, Student class, and Professor class with inheritance and association relationships] [Marks-8] | CLO-2 Level-4 According to the above class diagram, Figure out proper working code segments together. Must build the main method in a different class and inside the main method, make the object of each class. b) Figure out the output of the following code class Vehicle { void drive(){ System.out.println("Driving my vehicle..."); } void speedUp(){ System.out.println("Speeding up my Vehicle..."); } } class Car extends Vehicle{ void drive(){ System.out.println("Driving a car..."); } } class Main { public static void main(String[] args){ Vehicle v = new Car(); v.drive(); v.speedUp(); Car c = new Vehicle(); c.drive(); } } [Marks-2] |