Name (print): ________________________________
Honor Code Acknowledgment (sign): ________________________________________
Due: September 24, 1996
Prove by induction that any integer postage greater than 7 cents can be formed
using only 3-cent and 5-cent stamps.
For this problem, write a function called DoubleList to replace a linked list with a list that has two copies of each item in the original list, the two identical items should be adjacent.
For example, consider the following list:
DoubleList(list) would convert the list to:
Let each item in the list be represented by the struct Node:
struct Node
{
string name;
Node * next;
Node(string n, Node * ptr = 0)
{
name = n; next = ptr;
}
};