View Single Post
  #14   Spotlight this post!  
Unread 09-02-2004, 11:09
Jeff McCune's Avatar
Jeff McCune Jeff McCune is offline
Alpha Geek
#0677 (The Wirestrippers)
Team Role: Mentor
 
Join Date: Jan 2003
Location: The Ohio State University
Posts: 67
Jeff McCune is on a distinguished road
Send a message via ICQ to Jeff McCune Send a message via AIM to Jeff McCune
Re: Compiler Help Needed

Quote:
Originally Posted by Random Dude
Umm.. But (22/7) evaluates to (3).
My #define shouldn't include ( )'s. Then, if you use PI in an equation, it'll work just fine even though it's integer math.

#define PI 22 / 7
#define DIAMETER 10

circ = DIAMATER * PI; /* circ = 10 * 22 / 7 */
__________________
Team 677 - The Wirestrippers - Columbus School for Girls and The Ohio State University
EMAIL: mccune@ling.ohio-state.edu

...And all you touch and all you see
Is all your life will ever be...