Coin flip program on c++
<p>I am trying to make a program that will randomly show the outputs of a coin flipping until there are 5 heads in a row and then the program has to stop. I do not have a lot of experience coding so any help is appreciated!
So far all I have is a program that outputs the result of a coin flip one time.</p>

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

using namespace std;   

int main()   
{   
  srand (time(NULL));
  int flip = (rand()%2)+ 1 ;
  cout&lt;&lt;coin;
  return 0;
}
</code></pre>