Example #1
0
        public void parseLongTest()
        {
            long a;

            a = Long.parseLong("10000000000");
            Assert.AreEqual(10000000000, a);
            a = Long.parseLong("0");
            Assert.AreEqual(0, a);
            a = Long.parseLong("-10000000000");
            Assert.AreEqual(-10000000000, a);
        }
Example #2
0
 /// <summary>
 /// Scans the next token of the input as a long.
 /// </summary>
 /// <returns>the long scanned from the input
 /// </returns>
 public long nextLong()
 {
     return(Long.parseLong(getNextToken()));
 }