I don\'t want to do any rounding, straight up, \"39%\".
\"39%\"
So \"9.99%\" should become \"9%\".
\"9.99%\"
\"9%\"
I'm guessing you want a string returned? Probably the laziest way to do it:
string mynum = "39.999%" mynum = mynum.substring(0, mynum.IndexOf('.')); mynum += "%";
To get an int, you could cast the result of line 2.