private double _Subtotal;
get { return _Subtotal; }
set { _Subtotal = Subtotal; }
public clsFactura(double pSubtotal, double pTotal, double pIVA)
public string GenerarFactura(double mSubtotal, double mIVA)
TotalFactura = mSubtotal + ((mIVA/100)*(mSubtotal));
return string.Concat("El precio total es: ", TotalFactura, "$");
public static void Main()
clsFactura FacturaObj = new clsFactura(0, 0, 0);
Console.WriteLine("Ingresa el subtotal: \n");
Subtotal = double.Parse(Console.ReadLine());
Console.WriteLine("Ingresa el IVA: \n");
IVA = double.Parse(Console.ReadLine());
Console.WriteLine(FacturaObj.GenerarFactura(Subtotal, IVA));
Console.WriteLine("Hay un error");
Console.WriteLine("Chido");