Making the field repeat itself?
<p>This is my assignment for compsci and im stuck at the very end of how to get the field of stars '*' to repeat how ever many times the user wants. </p>

<p>Write a program that prints out a series of  fields of stars (i.e., “*”).  Each field will have n rows and m columns.  Enable the user to enter the number of rows (at least 1 but no more than 5) and columns (at least 5 but no more than 50), as well as the number of fields (at least 3, but no more than 10).  Each field must be separated by 3 complete blank lines.</p>

<p>Your program must include at least two functions: one to get the input data from the user, and one to draw each field.  Use for loops to construct the fields, as well as to print out the multiple fields.  Do NOT use a string of “<em>”.  Rather, print out individual “</em>”.</p>

<p>code</p>

<pre><code>#include &lt;iostream&gt;

using namespace std;

void displayField(int numrows, int numcolums);

void getData (int numrows, int numcolumns, int numfields);

const char c = '*';



int main(void)
{
    int numrows, numcolumns, numfields;

    cout &lt;&lt; "Welcome to the banner creation program!" &lt;&lt; endl;

    cout &lt;&lt; "Enter the number of rows (1 - 5) --&gt; ";
    cin &gt;&gt; numrows;

    if(numrows&lt;1 || numrows&gt;5){
        cout &lt;&lt; "Your entered value is outside the range!" &lt;&lt; endl;
        cout &lt;&lt; "Program will now halt..." &lt;&lt; endl;
        exit(0);}


    cout &lt;&lt; "Enter the number of columns (5 - 50) --&gt; ";
    cin &gt;&gt; numcolumns;

    if(numcolumns&lt;5 || numcolumns&gt;50){
        cout &lt;&lt; "Your entered value is outside the range!" &lt;&lt; endl;
        cout &lt;&lt; "Program will now halt..." &lt;&lt; endl;
        exit(0);
    }

    cout &lt;&lt; "Enter the number of rows (3 - 10) --&gt; ";
    cin &gt;&gt; numfields;

    if(numfields&lt;3 || numrows&gt;10){
        cout &lt;&lt; "Your entered value is outside the range!" &lt;&lt; endl;
        cout &lt;&lt; "Program will now halt..." &lt;&lt; endl;
        exit(0);
    }
for(int i=1; i&lt;=numrows; i++){
    for (int j=1; j&lt;=numcolumns; j++)
            cout &lt;&lt; c;
        cout &lt;&lt;endl;

}


}
</code></pre>
