CS311 Assignment 1 Solution Fall 2026

CS311 Introduction to Web Services Development Assignment 1 for Fall 2026 tests basic XML skills. Question 1 asks for a short XML code with a student root element holding a name and a VU student ID, with all tags closed correctly and proper indentation. Part A then asks for exact names from an event bookings XML tree: the root element, parents of booking and customer elements, the attributes that identify events and bookings, and the number of direct event children of the root. Part B asks for TRUE or FALSE answers on the same XML hierarchy.
The solution file linked below covers all three parts. Note that the XML code uses placeholders for the name and ID: replace them with your own full name and your own VU student ID before submitting, since the question asks for your actual details.
What Does the Solution File Cover?
What Is the XML Code?
The code declares XML version 1.0 with UTF-8 encoding, uses student as the root element, and places name and studentID inside it. Every opening tag has a matching closing tag, and the child elements are indented under the root. The code is well-formed, which means a parser accepts it without errors. Web foundations like this also appear in the CS202 Assignment 1 solution on HTML structure and in the IT430 Assignment 1 solution on building a web storefront.
What Are the Part A Tree Answers?
The root element name is eventBookings. The immediate parent of booking is event, and the immediate parent of customer is booking, which gives the nesting eventBookings, event, booking, customer. The attribute that identifies an event is code, and the attribute that identifies a booking is ref. The root has 2 direct event children. These answers describe a single consistent tree: two events sit directly under the root, each event holds bookings, and each booking holds its customer.
What Are the Part B TRUE FALSE Answers?
First, title and booking are sibling elements under event: TRUE, because both sit directly inside the same event element. Second, the value B102 is an element name: FALSE, because B102 is an attribute value (the kind of value carried by a ref or code attribute), not a tag name. Third, every category in the document is a child of booking: TRUE. Fourth, the VIP tag is present in the XML document: FALSE, since no such tag exists in the tree. Together, Parts A and B test whether you can read a hierarchy precisely instead of guessing from tag names.
How Do You Download the Solution File?
You can download the complete solution file from Google Drive using the link below. Before submitting, replace the placeholder name and ID in the XML code with your own details, and check the file against the exact assignment on VULMS, since question wording can vary.
Frequently Asked Questions
What is the difference between an XML element and an attribute?
An element is a tagged block of content, such as booking or customer, while an attribute is a name value pair written inside an opening tag, such as code or ref. In this assignment, B102 is an attribute value, not an element name, which is why the second Part B statement is FALSE.
What does well-formed XML mean?
Well-formed XML follows the basic syntax rules: exactly one root element, every opening tag closed, tags nested properly without overlap, and attribute values quoted. The Question 1 code meets all of these rules.
What are sibling elements?
Sibling elements share the same immediate parent. In this tree, title and booking are siblings because both sit directly under event. By contrast, customer is not a sibling of title, because customer sits under booking, one level deeper.
Do I submit the placeholder name and ID from the sample code?
No. The question asks for your actual full name and student ID, so replace the placeholders with your own details before submitting. Submitting someone else name or a placeholder ID would not match your record.
Last updated: November 2026.



