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

ios - Is 'init' forbidden as *part* of a variable name? -

file - Python: AttributeError: 'str' object has no attribute 'readlines' -

c# - Get the Class name in a class with atribute inside a attribute method -