linked list using a stack

I am having a hard time figuring out linked lists in C++.
I have to create a linked list using a stack template class, add the numbers from a text file to it, display them in original order, and reverse the linked list and output reversed linked list.
Here is what I have so far. I need help with building a linked list from a text file

#include <iostream>
#pragma once
#include <string>
using namespace std;

template <class T>
bool stackADT <T> :: EmptyStack ()
{
return (stackTop==NULL);
};

template <class T>
bool stackADT <T>:: FullStack ()
{
return false;
};

template <class T>
struct nodeType
{
T info;
nodeType <T> * link;
};

template <class T>
class StackADT{

public:
StackADT();
bool isEmpty() const;
bool isFull();
void Push(T item);
void Pop();
T Top() ;
~StackADT();

private:
nodeType <T> * stackTop;

};

template<class T> StackADT<T>::StackADT()
{
stackTop= NULL;
}


For starters, you may want to use the code, /code tags so that your program will be readable.
Topic archived. No new replies allowed.