0
can anyone help me with this code i C# ,, my output identical with expected output but its gives me error and i cant pass to the
int maxBid = Convert.ToInt32(Console.ReadLine()); while (true) { int bid = Convert.ToInt32(Console.ReadLine()); if (bid > maxBid) Console.WriteLine("Sold:" + bid); }
1 Resposta
+ 2
Only modify <maxBid> following <bid> inside the `if` conditional, but don't print anything yet. Print <maxBid> once only, after the while loop completed.
P.S. I'm not too sure about the use of `while( true )` loop to read the successive bidding inputs. Is there a limit - how many times biddings should be read? I forgot that one.