what the problem in this program? it doesn't use the second number, and doesn't print the last line? : <p>/<em>This program gets two positive numbers, declare "error" if the one of the numbers is negative, and then gets list
of numbers again and again until the amount of the list is bigger than the first number, or until the quantity of the
numbers in the list is equal to the second number, and ther prints the sum of the list.</em>/</p>

<pre><code>#include &lt;iostream&gt;
using namespace std;
int main()
{
    int num1, num2, num_list, tempSum, finalSum = 0, count = 0;
    cout &lt;&lt; "enter 2 positive numbers:" &lt;&lt; endl;
    cin &gt;&gt; num1;
    while (num1 &lt; 0)
    {
        cout &lt;&lt; "ERROR" &lt;&lt; endl;
        cin &gt;&gt; num1;
    }
    cin &gt;&gt; num2;
    while (num2 &lt; 0)
    {
        cout &lt;&lt; "ERROR" &lt;&lt; endl;
        cin &gt;&gt; num2;
    }
    cout &lt;&lt; "enter a list of numbers:" &lt;&lt; endl;
    do
    {
        cin &gt;&gt; num_list;
        tempSum = num_list;
        finalSum += tempSum;
        count = count + 1;
    } while (count &lt; num2 || finalSum &lt;= num1);
    cout &lt;&lt; finalSum &lt;&lt; endl;
    return 0;
}
</code></pre>
