HTML Displayer/Browser

Scott Dexter and Chaya Gurwitz
Department of Computer and Information Science
Brooklyn College of CUNY

In this series of assignments, students write a simplified version of a browser. We have used this assignment in a sophomore-level data structures course. In our department, that course is taught using C++. There are obvious extensions that can be made to this assignment that would take advantage of the gui and network capabilities of Java. However, the advantage of this assignment specifically in a C++ course is that it gives students a taste of programming an "Internet" application even in a non-Java course. The assignments are structured to provide "real-world" applications for data structures studied in class, rather than to develop a full-blown browser.

In the first part of the assignment, the students write a simplified HTML interpereter. We assign this immediately at the beginning of the semester, and it serves to provide a rigorous review of string manipulation and file management.

The second assignment uses the Stack data structure to extend the browser in two ways. A stack is used to detect additional syntax errors by checking for mismatched or incorrectly nested tags. Secondly, stacks are used to implement the "back" and "forward" browser features.

The third assignment uses a Queue data structure to provide a site-listing feature. We thought about (but didn't actually assign) a further assignment that would use tree data structures to build a site tree.



These executables are for Part II of the assignment. You may want to download the sample input files provided above; run the program from the directory in which the input files are stored.




Extra info about this assignment: