Program stops working when trying to fill an arrayof struct from a function
<p>im having a problem. everytime i try to give values to an array of struct from a function in a header file, my program stops working, and ends after windows tells me thar the program is not respoding. 
i coded a little example of the problem im having, so it can be read easier. it still crashes.
everything is part of a console application project.</p>

<p>here´s the main.cpp file:</p>

<pre><code>    #include &lt;iostream&gt;
    #include &lt;cstdlib&gt;
    #include &lt;string.h&gt;

    struct test{
    int number;
    char name[20];
    };

    #include "functions.h"

    using namespace std;

    int main()
    {
    test *arr[5];

    filleverything(*arr);

    return 0;
    }
</code></pre>

<p>And here´s the functions.h file:</p>

<pre><code>    #ifndef FUNCTIONS_H_INCLUDED
    #define FUNCTIONS_H_INCLUDED
    #include &lt;iostream&gt;
    #include &lt;cstdlib&gt;
    #include &lt;string.h&gt;

    using namespace std;

    void filleverything(test *arr){
    int i;
        for(i=0;i&lt;=5;i++){
            cout &lt;&lt; endl &lt;&lt; "Write a number: ";
            cin &gt;&gt; arr[i].number;
            cout &lt;&lt; endl &lt;&lt; "Write a name: ";
            cin &gt;&gt; arr[i].name;
        }
    }
</code></pre>

<p>this is a work for college, and we are not allowed to use global variables at all. also, the array has to be filled from the functions.h file using pointers, as im trying to do, with no success.
could anyone help me?</p>