1. PF Contest - Win "Conquering the Physics GRE" book! Click Here to Enter
    Dismiss Notice
Dismiss Notice
Join Physics Forums Today!
The friendliest, high quality science and math community on the planet! Everyone who loves science is here!

Boolean if exression

  1. Feb 6, 2007 #1
    I am trying to make a table that will output a value every ten years. Basically, I am incrementing the year by 1 in a while loop, and I want it so every time year=10, 20, 30... that it will output a value. I have:

    if (year%10 == 0) {
    ... code

    For some reason the compiler has trouble compiling this.

    *Nevermind, I had a typo and forgot the second =.
    Last edited: Feb 6, 2007
  2. jcsd
  3. Feb 7, 2007 #2


    User Avatar

    Staff: Mentor

    Glad you figured it out.
Know someone interested in this topic? Share this thread via Reddit, Google+, Twitter, or Facebook

Similar Threads - Boolean exression Date
(Boolean Algebra) Did I write this logic expression correctly? Jan 30, 2018
Setting up a truth table Jan 15, 2018
Simplifying switching circuit literals Sep 29, 2017