cs311 Assignment No 1 (2024)
cs311 Assignment No 1 (2024)
ASSAIGNMENT NO 1
(BC200418645)
Problem Statement:
You are required to write XML code for the following description of a
software
house.
<company>: This is the root element representing the software house company.
o <name>: Specifies the name of the company.
o <location>: Contains information about the company's location.
<city>: Specifies the city where the company is located.
<country>: Specifies the country where the company is located.
o <departments>: Contains a list of departments within the company.
<department>: Represents a single department within the company.
<name>: Specifies the name of the department.
<employees>: Contains a list of employees within the department.
<employee>: Represents a single employee within the
department.
<name>: Specifies the name of the employee.
<position>: Specifies the position or role of the
employee.
o <projects>: Contains a list of projects being undertaken by the company.
<project>: Represents a single project.
<name>: Specifies the name of the project.
<department>: Specifies the department responsible for the
project.
<status>: Specifies the current status of the project (e.g., "In
Progress", "Completed").
Solution:
<company>
<name>ABC-SOFTWARE-HOUSE</name>
<location>
<city>LAHORE</city>
<country>PAKISTAN</country>
</location>
<departments>
<department>
<name>DEVELOPENT</name>
<employees>
<employee>
<name>Ibrahim-Ahmed</name>
<position>Senior-Developer</position>
</employee>
<employee>
<name>Arslan-Afzal</name>
<position>UI/UX-DESIGNER</position>
</employee>
</employees>
</department>
<department>
<name>ENGINEERING</name>
<employees>
<employee>
<name>SAAD-SAJID</name>
<position>SOFTWARE-ENGINEER</position>
</employee>
<employee>
<name>USMAN-KHAN</name>
<position>UI/UX-DESIGNER</position>
</employee>
</employees>
</department>
</departments>
<projects>
<project>
<name>SOCIAL-MEDIA-MARKETING</name>
<department>MARKITING</department>
<status>IN-PROGRESS</status>
</project>
<project>
<name>ONLINE-SHOPPING-APP</name>
<department>ENGINEERING</department>
<status>IN-PROGRESS</status>
</project>
<project>
<name>MOBILE-PAYMENT-INTEGRATION</name>
<department>ENGINEERING</department>
<status>COMPLETED</status>
</project>
</projects>
</company>