This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| /** | |
| * @brief Remove Node of data "T" from end of list | |
| * | |
| * @param targetData the data to remove from the list | |
| */ | |
| template <class T> | |
| void LinkedList<T>::removeNode(T targetData) | |
| { | |
| if (head<T> == NULL) | |
| { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| /** | |
| * @brief Add Node of data "T" to end of list | |
| * | |
| * @param targetData the data to add to the list | |
| */ | |
| template <class T> | |
| void LinkedList<T>::addNode(T targetData) | |
| { | |
| Node<T> *temp = new Node<T>(targetData); // create a temp Node |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| template <typename T> | |
| struct Node | |
| { | |
| /** | |
| * @brief the Node's data | |
| */ | |
| T data; | |
| /** | |
| * @brief the pointer to the next Node |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| template <typename T> | |
| struct Node | |
| { | |
| /** | |
| * @brief the Node's data | |
| */ | |
| T data; | |
| /** | |
| * @brief the pointer to the next Node |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| // p01.cxx | |
| // oberoi, sean | |
| // ssoberoi | |
| #include <iostream> | |
| int getLargest(int values[], size_t length); | |
| int main() | |
| { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #include <iostream> | |
| #include<fstream> | |
| #define ARRAY_LEN 30 | |
| using namespace std; | |
| float average(float* array, int num_elements); | |
| int main() | |
| { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #include <iostream> | |
| #include <iterator> | |
| #define CHOICE_RANGE 3 | |
| #define VECTOR_LEN 3 | |
| using namespace std; | |
| struct Player | |
| { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #include <iostream> | |
| #include "tgmath.h" | |
| using namespace std; | |
| void checkAge(int*); | |
| int main() | |
| { | |
| cout << "Enter your age: "; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #include <iostream> | |
| using namespace std; | |
| class Token | |
| { | |
| public: | |
| char kind; | |
| double value; | |
| Token (char ch) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #include <iostream> | |
| #include "tgmath.h" | |
| // For the sake of not having to prepend datatypes with std:: :P | |
| using namespace std; | |
| int main () | |
| { | |
| cout << "Enter a number 1-4 digits: "; | |
| string num; |
NewerOlder