Created
May 14, 2017 03:15
-
-
Save YhorbyMatias/29312e0de6da1417e8677c67efdf63e7 to your computer and use it in GitHub Desktop.
Simulando venta restaurant
This file contains hidden or 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
using System; | |
namespace Demo20 | |
{ | |
class MainClass | |
{ | |
public static void Main(string[] args) | |
{ | |
byte CAMB, CANH, CANP; | |
double APAGAR; | |
string linea; | |
const double PrecioB = 0.8; | |
const double PrecioH = 2; | |
const double PrecioP = 1.2; | |
Console.WriteLine("Cantidad Plato Aji de gallina"); | |
linea = Console.ReadLine(); | |
CANH = byte.Parse(linea); | |
Console.WriteLine("Cantidad de plato de arroz"); | |
linea = Console.ReadLine(); | |
CANP = byte.Parse(linea); | |
Console.WriteLine("Cantidad de refrescos"); | |
linea = Console.ReadLine(); | |
CAMB = byte.Parse(linea); | |
Console.WriteLine(); | |
APAGAR = (CANH * PrecioH) + (CANP * PrecioP) + (CAMB * PrecioB); | |
Console.WriteLine("TOTAL A PAGAR \n" + APAGAR); | |
Console.ReadKey(); | |
} | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment