Official Forum for Programming in Objective-C (the iPhone Programming Language) - Stephen Kochan
October 18, 2017, 06:39:38 PM *
Welcome, Guest. Please login or register.
Did you miss your activation email?

Login with username, password and session length
 
   Home   Help Search Login Register Chat  
Pages: [1]   Go Down
  Print  
Author Topic: Problem 9 - 2, Programming in C  (Read 11172 times)
omegaMan
Newbie
*
Posts: 8


Email
« on: April 11, 2010, 05:37:42 PM »

The initial equations for N1 and N2 are either wrong or I don't get them. The formula for N ends with the term "+day" which, for August 8, 2004 should be 8, not 3 as the book shows. Also, the N2 calculation for February 22, 2005 should end with +22 not +21 as the book shows, shouldn't it? Additionally, it is not stated anywhere in the problem but I assume all divisions carried out are integer divisions. Is all this correct?
Logged
skochan
Administrator
Hero Member
*****
Posts: 3114



« Reply #1 on: April 12, 2010, 06:13:46 AM »

Yes, it's all integer division.  And yes, your corrections to the numbers in the example are correct.

Thanks,

Steve Kochan
Logged
Tfazio
Newbie
*
Posts: 2


Email
« Reply #2 on: May 08, 2011, 05:38:26 PM »

RE: ex 9.2. I found this example very confusing. I'm sure trying to decipher the math was not the point of the exercise.
This is the point in the book where I get lost not having a strong math background. Any clarity would be appreciated.
I otherwise found this book very helpful. tf
Logged
A31Chris
Newbie
*
Posts: 20


Email
« Reply #3 on: June 10, 2011, 01:22:41 AM »

whoa okay this clear up a lot for me. I think. thanks! Smiley
Logged
A31Chris
Newbie
*
Posts: 20


Email
« Reply #4 on: June 10, 2011, 02:07:41 AM »

Hell I didnt look at the formula too close and thought it was some set boilerplate formula for this.Wondered why the formula for n1 and n2 were different.

why wasnt it just explained as something like: i=1461*f/4+153*g/5+(whatever day variable or structure day variable here);
Logged
Pages: [1]   Go Up
  Print  
 
Jump to:  

Powered by MySQL Powered by PHP Powered by SMF 1.1.11 | SMF © 2006-2009, Simple Machines LLC Valid XHTML 1.0! Valid CSS!
Entire forum contents ゥ 2009 classroomM.com. All rights reserved.