Simple while loop problem

Can someone please tell me what is wrong with this? It never breaks out of the while loop. Thanks

1
2
3
4
5
6
7
8
9
10
11
12
cout<<sum<<" is the point!"<<endl;
point = sum;
                        
while ((sum != point) || (sum != 7))
{
cout<<"Enter 1 to roll again"<<endl;
cin>>pause;
roll1=dice();
roll2=dice();
sum = roll1 + roll2;
cout<<"You rolled a "<<sum<<"."<<endl;
}
A full posting of your code is required to figure this out.
Last edited on
I figured it out. I had to change || to &&. Stupid mistake. Thanks anyway.
Topic archived. No new replies allowed.