Last active
July 17, 2016 16:00
-
-
Save aveao/dccec7f309bf6caafd55 to your computer and use it in GitHub Desktop.
Steam Level/Price calculator
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
int SteamLevel = 1111; //edit this as you want | |
double PricePerBadge = 0.4; //change this for yourself | |
double price = 0; //don't touch | |
for (int i = 0; i < SteamLevel; i++) | |
{ | |
price += (Math.Floor((double)(i/10))+1)*PricePerBadge; | |
} | |
Console.WriteLine(price.ToString()); | |
//I coded this on http://csharppad.com/, that is why this looks a bit weird. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
int FromSteamLevel = 33; //edit this as you want | |
int ToSteamLevel = 35; //edit this as you want | |
double PricePerBadge = 0.4; //change this for yourself | |
double price = 0; //don't touch | |
for (int i = FromSteamLevel; i < ToSteamLevel; i++) | |
{ | |
price += (Math.Floor((double)(i/10))+1)*PricePerBadge; | |
} | |
Console.WriteLine(price.ToString()); | |
//I coded this on http://csharppad.com/, that is why this looks a bit weird. |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment