I am trying to create a program that calculates the cost of one atom of an element but when I run the code this line...
gets an error that says "DivideByZeroEx ception was unhandled" I think it may be because my "decNumPerSampl e" is somewhere around .00000000000000 000000000007985 and I think it is rounding down to zero.
How do I fix this problem.
Code:
decCostPerSingle = decSampleCost / decNumPerSample
How do I fix this problem.
Comment