Simple Divisibility
<p>when I run this program it get stuck in a loop of asking me to "Enter Value: " and continues to add one to the sum. Although this is exactly what it is supposed to do, if I enter a number that is divisible by 6 or 17 the loop doesn't end. Can explain why?</p>

<p>import java.util.Scanner;</p>

<pre><code>public class DivisibleBy6or17 {
   public static void main(String[] args){          
   Scanner in = new Scanner(System.in);
   System.out.print("Enter Value: ");
   int one = in.nextInt();
   int sum=0;

   while (one % 6 != 0||one % 17 != 0) {
       System.out.print("Enter Value: ");
       one = in.nextInt();
       sum++;
   }

   System.out.print("Numbers read: " + sum);
   }
}
</code></pre>
