c# - Division in double variable returning always zero -


i trying perform division , multiplication between 2 values , save them in double variable.

multiplication working fine division returning 0 ?

why ?

here code :

double max_load =(convert.todouble(ddl_gene_desc.selectedvalue)*0.8)*(80/100); 

i checked using breakpoint multiplication fine (80/100) returning 0.

can 1 please me ?

thanks in advance.

the result of 80/100 (both integers) 0.

change 80.0/100.0


Comments

Popular posts from this blog

sequelize.js - Sequelize group by with association includes id -

android - Robolectric "INTERNET permission is required" -

java - Android raising EPERM (Operation not permitted) when attempting to send UDP packet after network connection -