Porque cuando ingreso un nĂșmero mayor a 50,000 me muestra "Accepted" y no "Error"?
using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.Threading.Tasks; namespace SoloLearn { class Program { static void Main(string[] args) { int pay = Convert.ToInt32(Console.ReadLine()); Payment pay1 = new Payment(); pay1.PaymentValue = pay; } } class Payment { private int paymentValue; //completa la propiedad public int PaymentValue { get {return paymentValue;} set { if(paymentValue > 50000) Console.WriteLine("Error"); else Console.WriteLine("Accepted"); } } } }