import StdEnv
import Data.Func
-import qualified Data.Set
-import Text
+import qualified Data.Set as DS
getinput f
# (ok, c, f) = freadc f
split c [r:rest] = split [r:c] rest
Start w
-# (_, io, w) = fopen "input.txt" FReadText w
-= proc 'Data.Set'.newSet
+# (io, w) = stdio w
+= proc 'DS'.newSet
$ scan (+) 0
$ map (toInt o toString)
$ flatten
$ getinput io
proc have [x:xs]
- | 'Data.Set'.member x have = x
- = proc ('Data.Set'.insert x have) xs
+ | 'DS'.member x have = x
+ = proc ('DS'.insert x have) xs