Submission #1842397
Source Code Expand
import java.util._ import java.io._ import scala.collection.mutable._ import scala.util.control._ object Main { def main(args:Array[String])={ val a = Scanner.nextInt println(a*2) } } object Scanner{ private val buf = new Array[Byte](1024) private var ptr = 0 private var len = 0 @inline private def isPrintableChar(c: Int): Boolean = 33 <= c && c<= 126 @inline private def hasNextByte(): Boolean = if(len <= ptr){ptr = 0;len = System.in.read(buf);len > 0} else { true } @inline private def hasNext(): Boolean = { while(hasNextByte() && !isPrintableChar(buf(ptr))) ptr += 1 hasNextByte() } @inline private def readByte(): Byte = if(hasNextByte()){val res = buf(ptr); ptr+=1; res}else{ -1 } def next(): String = { val s = new StringBuilder var b = readByte() while(isPrintableChar(b)){ s.append(b.toChar); b = readByte() } s.toString } def nextInt(): Int = nextLong.toInt def nextLong(): Long = { var minus = false var b = readByte if(b == '-'){minus = true; b=readByte()} def go(b: Byte, n:Long = 0):Long = if ('0' <= b && b <= '9') { go(readByte(), n * 10 + b - '0') } else if (minus) { -n } else { n } go(b) } def nextDouble(): Double = next.toDouble }
Submission Info
Submission Time | |
---|---|
Task | A - 流行 |
User | lrf141 |
Language | Scala (2.11.7) |
Score | 100 |
Code Size | 1311 Byte |
Status | AC |
Exec Time | 323 ms |
Memory | 27196 KB |
Judge Result
Set Name | All | ||
---|---|---|---|
Score / Max Score | 100 / 100 | ||
Status |
|
Set Name | Test Cases |
---|---|
All | 00_sample_00.txt, max_1000000.txt, min_0.txt, rand_133007.txt, rand_171937.txt, rand_172717.txt, rand_232508.txt, rand_242450.txt, rand_246841.txt, rand_269046.txt, rand_320433.txt, rand_435534.txt, rand_50616.txt, rand_537196.txt, rand_565439.txt, rand_601980.txt, rand_622146.txt, rand_624081.txt, rand_678601.txt, rand_696476.txt, rand_762274.txt, rand_798714.txt, rand_821336.txt, rand_85323.txt, rand_859632.txt, rand_921203.txt, rand_934508.txt, rand_993594.txt |
Case Name | Status | Exec Time | Memory |
---|---|---|---|
00_sample_00.txt | AC | 321 ms | 23880 KB |
max_1000000.txt | AC | 318 ms | 25400 KB |
min_0.txt | AC | 316 ms | 25244 KB |
rand_133007.txt | AC | 313 ms | 25020 KB |
rand_171937.txt | AC | 317 ms | 25148 KB |
rand_172717.txt | AC | 313 ms | 25024 KB |
rand_232508.txt | AC | 317 ms | 25396 KB |
rand_242450.txt | AC | 316 ms | 25368 KB |
rand_246841.txt | AC | 317 ms | 25272 KB |
rand_269046.txt | AC | 314 ms | 27196 KB |
rand_320433.txt | AC | 323 ms | 25260 KB |
rand_435534.txt | AC | 318 ms | 23744 KB |
rand_50616.txt | AC | 320 ms | 25128 KB |
rand_537196.txt | AC | 316 ms | 25268 KB |
rand_565439.txt | AC | 316 ms | 25284 KB |
rand_601980.txt | AC | 315 ms | 25140 KB |
rand_622146.txt | AC | 316 ms | 23368 KB |
rand_624081.txt | AC | 316 ms | 25240 KB |
rand_678601.txt | AC | 319 ms | 25392 KB |
rand_696476.txt | AC | 321 ms | 25104 KB |
rand_762274.txt | AC | 318 ms | 25416 KB |
rand_798714.txt | AC | 317 ms | 25272 KB |
rand_821336.txt | AC | 318 ms | 25136 KB |
rand_85323.txt | AC | 321 ms | 25372 KB |
rand_859632.txt | AC | 319 ms | 25260 KB |
rand_921203.txt | AC | 319 ms | 25272 KB |
rand_934508.txt | AC | 316 ms | 23612 KB |
rand_993594.txt | AC | 318 ms | 25284 KB |