Loading problem…
Design a browser history manager with back and forward navigation.
Implement:
Behavior:
visit(url) navigates to a new page and clears forward historyback(steps) moves back up to steps times and returns the current URLforward(steps) moves forward up to steps times and returns the current URLback/forward should clamp to valid bounds