How would I implement code in a .h file into the main.cpp file?
<p>I have a c++ project I am working on. I am a little stumped at the moment. I need a little help. I need to implement code from the .h file into the main.cpp file and I am not sure how to do that. </p>

<p>For example code code from main.cpp:</p>

<pre><code>switch (choice){
case 1: // open an account
    {
    cout &lt;&lt; "Please enter the opening balence: $ ";
    cin &gt;&gt; openBal;
    cout &lt;&lt; endl;
    cout &lt;&lt; "Please enter the account number: ";
    cin &gt;&gt; accountNum;
    cout &lt;&lt; endl;

    break;
    }
case 2:// check an account
    {
    cout &lt;&lt; "Please enter the account number: ";
    cin &gt;&gt; accountNum;
    cout &lt;&lt; endl;
    break;
    }
</code></pre>

<p>and code from the .h file:</p>

<pre><code>void display(ostream&amp; out) const;
// displays every item in this list through out

bool retrieve(elemType&amp; item) const;
// retrieves item from this list
// returns true if item is present in this list and
//              element in this list is copied to item
//         false otherwise

// transformers
void insert(const elemType&amp; item);
// inserts item into this list
// preconditions: list is not full and
//                item not present in this list
// postcondition: item is in this list
</code></pre>

<p>In the .h file you would need to use the void insert under transformer in the main.cpp under case 1. How would you do that? Any help is apprecaited. I hope I didn't confuse anyone on what I am needing to know how to do. Thanks</p>
