Computer Science > STUDY GUIDE > University of Texas, Rio Grande Valley - CSCI 2380browserhistory (1).cpp (All)
// Carlos Avila #include "browserhistory.h" BrowserHistory::BrowserHistory(string default_url) { // Creates a new browser history with only one page visited: default_url Node* temp = new Node(); ... temp->url = default_url; temp->next = temp->prev = nullptr; head = tail = current = temp; // have one website only (defult_url) } string BrowserHistory::current_url() { // Returns the current page. return current->url; } void BrowserHistory::go_to_url(string url) { // Moves the browser to a new page url via, // enters a new url (new Node in the linked list) Node* a = new Node(); a->url = url; a->prev = current; current->next =a; hea [Show More]
Last updated: 1 year ago
Preview 1 out of 3 pages
Connected school, study & course
About the document
Uploaded On
Mar 28, 2021
Number of pages
3
Written in
This document has been written for:
Uploaded
Mar 28, 2021
Downloads
0
Views
50
In Browsegrades, a student can earn by offering help to other student. Students can help other students with materials by upploading their notes and earn money.
We're available through e-mail, Twitter, Facebook, and live chat.
FAQ
Questions? Leave a message!
Copyright © Browsegrades · High quality services·