0
Posted on 7:11 AM by Softminer and filed under

if you divide two int then the result is always integer even if you save it in Decimal.

int A = 32;
int B = 36;
decimal result = A / B;

then the result = 0

but if you use
decimal A = 32;
decimal B = 36;
decimal result = A / B;

then the result = 0.8888888888
0
Responses to ... Decimal division problem in C#