While loop using &&

While loops only continue running WHILE BOTH conditions are true, not until they become true. If you want the program to stop once both conditions are true just use a negation.

!(programsdone<5 && result<50)

Leave a Comment