DOH! That would make sense!
Actually: I fixed the problem by casting it before i set the variable so:
double headsPercentage = 100 * ((double)totalNumberOfHeads / totalNumberOfTosses);
double...
Type: Posts; User: CameronFaust
DOH! That would make sense!
Actually: I fixed the problem by casting it before i set the variable so:
double headsPercentage = 100 * ((double)totalNumberOfHeads / totalNumberOfTosses);
double...
I cannot for the life of me figure out why headsPercentage and tailsPercentage always = 0! I've debugged step by step and totalNumberOfHead, totalNumberOfTails, and totalNumberOfTosses are never 0....