Submission #4651545
Source Code Expand
fun readInt () = TextIO.scanStream (Int.scan StringCvt.DEC) TextIO.stdIn val SOME x = readInt () vel a = (x + 1) * 5000 val () = print (Int.toString a ^ "\n")
Submission Info
Submission Time | |
---|---|
Task | A - 正直者 |
User | mine691 |
Language | Standard ML (MLton 20100608) |
Score | 0 |
Code Size | 165 Byte |
Status | CE |
Compile Error
Error: Main.sml 4.2. Undefined variable vel. Error: Main.sml 3.15. Function not of arrow type. function: [int option] in: (readInt ()) vel Error: Main.sml 4.6. Undefined variable a. Error: Main.sml 4.11. Undefined variable x. Error: Main.sml 3.6. Pattern and expression disagree. pattern: [??? option] expression: [bool] in: SOME x = readInt () vel a = (x + 1) * 5000 Error: Main.sml 6.31. Undefined variable a. Warning: Main.sml 3.2. Unable to locally determine type of variable: x. type: ??? in: val SOME x = readInt () vel a = (x + 1) * 5000 compilation aborted: parseAndElaborate reported errors