Rounding values up or down in C#

Posted by c11ada on Stack Overflow See other posts from Stack Overflow or by c11ada
Published on 2010-04-13T19:56:45Z Indexed on 2010/04/13 20:03 UTC
Read the original article Hit count: 258

Filed under:
|
|

Hey all,

I've created a game which gives a score at the end of the game, but the problem is that this score is sometimes a number with a lot of digits after the decimal point (like 87.124563563566). How would I go about rounding up or down the value so that I could have something like 87.12?

Thanks!

© Stack Overflow or respective owner

Related posts about c#

Related posts about numbers