ASSIGNMENT NO.1 SOLUTION, Assignments of Software Engineering

Exact solution of assignment no.1

Typology: Assignments

2022/2023

Uploaded on 05/25/2023

batool-batool-1
batool-batool-1 🇵🇰

1 document

1 / 3

Toggle sidebar

This page cannot be seen from the preview

Don't miss anything!

bg1
CS603 Assignment No.1
Question No.1:
Create a UML class diagram that models different types of vehicles. Use inheritance to represent the
relationships between the vehicle class and its subclasses (such as car, truck, and motorcycle).
Solution:
Main Class
In the above class diagram, the vehicle class is the base class representing common attributes and
behaviors of vehicles. The truck, vehicle and bike classes are subclasses that acquire from the
pf3

Partial preview of the text

Download ASSIGNMENT NO.1 SOLUTION and more Assignments Software Engineering in PDF only on Docsity!

CS603 Assignment No.

Question No.1: Create a UML class diagram that models different types of vehicles. Use inheritance to represent the relationships between the vehicle class and its subclasses (such as car, truck, and motorcycle). Solution : Main Class In the above class diagram, the vehicle class is the base class representing common attributes and behaviors of vehicles. The truck, vehicle and bike classes are subclasses that acquire from the

vehicle class, addressing explicit sorts of vehicles. Every subclass adds its own one of a kind way of behaving and credits. Question No.2: Create a UML class diagram that models a computer system. Use composition to represent the relationships between the system and its software components (such as the operating system and applications). Solution: In the above class diagram, the OS class represents the operating system component of computer system. It has two attributes name and vision along with method to getName and getVersion and boot the OS. The ComputerSystem class represents a computer system. It has composition relationship with OS class and App class.