title: Print out odd numbers 0-100, excluding X, Y, Z
body: <p>This is obviously a "Homework style" task, but I have issues with grasping how I can exclude a certain set of numbers. I understand how I can write out the odd numbers from 0-100, but I fail to comprehend any answers I've found, or tried to find, about how to exclude pre-set numbers of choice.</p>
  
  <p>Basically, what I want to happen is the following:
  The program writes all odd numbers from 1-100. Lets say I don't want the numbers 5,9 or 11 to be displayed, but I want my program to continue, how do I make that happen? </p>
  
  <p>I have two different sets of code (I don't know which is easier to use in this context, so I'm including both of them):</p>
  
  <pre><code>for (int i=0; i&lt;100; i++)
  
              if (i % 2 !=0)
          System.out.println(i)
  </code></pre>
  
  <p>and</p>
  
  <pre><code>for (int i=1; i&lt;100; i=i+2)
  System.out.println(i)
  </code></pre>