Page t020, go to NEXT, PREVIOUS, INDEX

Coding Styles


C is free form

Common styles for if block are

      if (x < 0) {
        y = -x;
      } else {
        y = x;
      }

or

      if (x < 0)
      { y = -x;
      }
      else
      { y = x;
      }

C Course, 20-jan-1997, Peter Klok, pfk@hef.kun.nl