Last active
May 8, 2022 15:16
-
-
Save ghostofgamer/ac9d9c0a14ea98a335e0314e5e3e38c5 to your computer and use it in GitHub Desktop.
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 gold; | |
int priceCristall = 15; | |
int amountCristalls; | |
int payGold; | |
Console.Write("Сколько у вас золота?: "); | |
gold = Convert.ToInt32(Console.ReadLine()); | |
Console.WriteLine("Предлагаю вам кристаллы по цене " + priceCristall + " золота за штуку, сколько вам завернуть?"); | |
amountCristalls = Convert.ToInt32(Console.ReadLine()); | |
payGold = amountCristalls * priceCristall; | |
gold = gold - payGold; | |
Console.WriteLine("Заберайте свои " + amountCristalls + " кристаллов за " + payGold + " золота,удачи!"); | |
Console.WriteLine("осталось денег: " + gold ); | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment