Assignment 1 1-1
Assignment 1 1-1
General Rules
An open tag and a close tag match if all of the following are true:
1. The name of the open tag matches the name of the close tag. For example,
the names in the open and close tags <h1> and </ H1 > match, but the
names in the open and close tags <div> and </p> don't match.
2. The open tag precedes the close tag in the document. For example, the
open tag precedes the close tag in
3. ... <p> ... </p> ...
The Problem
Write a C++ program that reads an HTML document and validate HTML. During
validation it checks whether HTML tag is valid or not and HTML tags are
properly nested in the document. You can read a list of valid HTML tags from a
file and store in a vector. In case of valid HTML tags and properly nested tags
your program should output “Valid HTML document”; otherwise, it should
output an informative error and stop.