.net - Unpexpected Result of Division C# -


i tried doing following:

math.log10(11/10);  

expected answer 0.04139268515822504075019997124302

c# answer 0.0

really strange!! missing in finding log? need help

you should put like

  math.log10(11.0/10.0);  

otherwise 11 / 10 result in 1 (integer division) , logarithm in 0 correspondingly


Comments

Popular posts from this blog

windows - Single EXE to Install Python Standalone Executable for Easy Distribution -

c# - Access objects in UserControl from MainWindow in WPF -

javascript - How to name a jQuery function to make a browser's back button work? -