I am using the following code to come up with a number.
NSString *userNameOne = txtUserName.text;
double numOne = [userNameOne intValue];
double agedecade = numOne/10;
double betaage = 0.23260;
double meanage = 5.64301;
double one_age = agedecade - meanage;
double age_final_var = one_age * betaage;
If the user input 55 into the numOne
variable, the answer will be -.033264 using the above program.
However, if I do the same on a calculator I get -.033264126. I would like to get the extra three digits into my program. How do I get the missing three digits (...126) into my program above?
** I happen to be using this code in an iPhone App, saying this in case this changes things.