Exemple #1
0
        public long ReadInputInt()
        {
            var wait = new SpinWait();

            ReadingInt?.Invoke(this, EventArgs.Empty);

            while (_inputBuffer.Count < 1)
            {
                wait.SpinOnce();
            }

            return(_inputBuffer.Dequeue());
        }
Exemple #2
0
 public long ReadInputInt()
 {
     ReadingInt?.Invoke(this, EventArgs.Empty);
     return(long.Parse(Console.ReadLine()));
 }