Result

WA

Duration

1612ms

Code [DL]

package main

import (
	b "bufio"
	"os"
)

func main() {
	s := b.NewScanner(os.Stdin)
	for i := 0; i < 32; i++ {
		s.Scan()
		s := s.Text()
		if s[1] == s[2] {
		  print(s[2] - '0')
		} else {
			print(s[4] - '0')
		}
	}
}

stdin

522 221
433 176
796 962
455 527
783 834
511 148
125 754
486 722
328 851
887 799
956 527
554 263
366 765
948 447
437 733
234 414
459 493
722 332
346 421
277 896
799 297
412 227
474 559
699 776
922 226
172 221
659 959
621 558
491 592
687 332
594 997
796 197

stdout

stderr

23958177875264744247925922955391

strace

10    execve("/bin/sh", ["/bin/sh", "/root/script", "/volume/CODE"], 0x7fff3de36b30 /* 7 vars */) = 0
11    execve("/usr/bin/realpath", ["realpath", "/volume/CODE"], 0x55ade7799d18 /* 7 vars */) = 0
11    +++ exited with 0 +++
10    --- SIGCHLD {si_signo=SIGCHLD, si_code=CLD_EXITED, si_pid=11, si_uid=0, si_status=0, si_utime=0, si_stime=0} ---
12    execve("/bin/ln", ["ln", "-sf", "/volume/CODE", "/tmp/code.go"], 0x55ade7799d38 /* 7 vars */) = 0
12    +++ exited with 0 +++
10    --- SIGCHLD {si_signo=SIGCHLD, si_code=CLD_EXITED, si_pid=12, si_uid=0, si_status=0, si_utime=0, si_stime=0} ---
13    execve("/usr/bin/go", ["/usr/bin/go", "build", "-o", "/tmp/code", "/tmp/code.go"], 0x55ade779c028 /* 7 vars */) = 0
19    execve("/usr/lib/go/pkg/tool/linux_amd64/compile", ["/usr/lib/go/pkg/tool/linux_amd64"..., "-V=full"], 0xc00033c270 /* 25 vars */) = 0
20    execve("/usr/lib/go/pkg/tool/linux_amd64/compile", ["/usr/lib/go/pkg/tool/linux_amd64"..., "-V=full"], 0xc00032b110 /* 25 vars */) = 0
22    +++ exited with 0 +++
23    +++ exited with 0 +++
21    +++ exited with 0 +++
19    +++ exited with 0 +++
18    --- SIGCHLD {si_signo=SIGCHLD, si_code=CLD_EXITED, si_pid=19, si_uid=0, si_status=0, si_utime=0, si_stime=1} ---
25    execve("/usr/lib/go/pkg/tool/linux_amd64/asm", ["/usr/lib/go/pkg/tool/linux_amd64"..., "-V=full"], 0xc00033c4e0 /* 25 vars */) = 0
27    +++ exited with 0 +++
28    +++ exited with 0 +++
26    +++ exited with 0 +++
20    +++ exited with 0 +++
18    --- SIGCHLD {si_signo=SIGCHLD, si_code=CLD_EXITED, si_pid=20, si_uid=0, si_status=0, si_utime=0, si_stime=0} ---
29    execve("/usr/lib/go/pkg/tool/linux_amd64/asm", ["/usr/lib/go/pkg/tool/linux_amd64"..., "-V=full"], 0xc00033c680 /* 25 vars */) = 0
30    +++ exited with 0 +++
31    +++ exited with 0 +++
32    +++ exited with 0 +++
25    +++ exited with 0 +++
18    --- SIGCHLD {si_signo=SIGCHLD, si_code=CLD_EXITED, si_pid=25, si_uid=0, si_status=0, si_utime=0, si_stime=0} ---
33    +++ exited with 0 +++
34    +++ exited with 0 +++
35    +++ exited with 0 +++
29    +++ exited with 0 +++
18    --- SIGCHLD {si_signo=SIGCHLD, si_code=CLD_EXITED, si_pid=29, si_uid=0, si_status=0, si_utime=0, si_stime=0} ---
37    execve("/usr/lib/go/pkg/tool/linux_amd64/compile", ["/usr/lib/go/pkg/tool/linux_amd64"..., "-o", "/tmp/go-build247832844/b001/_pkg"..., "-trimpath", "/tmp/go-build247832844/b001=>", "-p", "main", "-complete", "-buildid", "F9llmTuYirBVxLxMfUTz/F9llmTuYirB"..., "-goversion", "go1.13.10", "-D", "_/tmp", "-importcfg", "/tmp/go-build247832844/b001/impo"..., "-pack", "-c=2", "/tmp/code.go"], 0xc0000ee410 /* 25 vars */) = 0
41    +++ exited with 0 +++
40    +++ exited with 0 +++
39    +++ exited with 0 +++
38    +++ exited with 0 +++
37    +++ exited with 0 +++
24    --- SIGCHLD {si_signo=SIGCHLD, si_code=CLD_EXITED, si_pid=37, si_uid=0, si_status=0, si_utime=1, si_stime=0} ---
42    execve("/usr/lib/go/pkg/tool/linux_amd64/link", ["/usr/lib/go/pkg/tool/linux_amd64"..., "-V=full"], 0xc000082410 /* 25 vars */) = 0
43    +++ exited with 0 +++
44    +++ exited with 0 +++
46    +++ exited with 0 +++
45    +++ exited with 0 +++
42    +++ exited with 0 +++
36    --- SIGCHLD {si_signo=SIGCHLD, si_code=CLD_EXITED, si_pid=42, si_uid=0, si_status=0, si_utime=0, si_stime=0} ---
47    execve("/usr/lib/go/pkg/tool/linux_amd64/link", ["/usr/lib/go/pkg/tool/linux_amd64"..., "-o", "/tmp/go-build247832844/b001/exe/"..., "-importcfg", "/tmp/go-build247832844/b001/impo"..., "-buildmode=exe", "-buildid=ZqxUcYk5rRl6sfOLrp0Q/F9"..., "-extld=gcc", "/tmp/go-build247832844/b001/_pkg"...], 0xc000082d00 /* 25 vars */) = 0
50    +++ exited with 0 +++
48    +++ exited with 0 +++
49    +++ exited with 0 +++
47    +++ exited with 0 +++
36    --- SIGCHLD {si_signo=SIGCHLD, si_code=CLD_EXITED, si_pid=47, si_uid=0, si_status=0, si_utime=13, si_stime=3} ---
36    +++ exited with 0 +++
24    +++ exited with 0 +++
18    +++ exited with 0 +++
17    +++ exited with 0 +++
16    +++ exited with 0 +++
14    +++ exited with 0 +++
15    +++ exited with 0 +++
13    +++ exited with 0 +++
10    --- SIGCHLD {si_signo=SIGCHLD, si_code=CLD_EXITED, si_pid=13, si_uid=0, si_status=0, si_utime=4, si_stime=10} ---
51    execve("/bin/cat", ["cat", "-"], 0x55ade7799d08 /* 7 vars */ <unfinished ...>
52    execve("/tmp/code", ["/tmp/code"], 0x55ade7799cf0 /* 7 vars */ <unfinished ...>
51    <... execve resumed>)             = 0
52    <... execve resumed>)             = 0
51    +++ exited with 0 +++
10    --- SIGCHLD {si_signo=SIGCHLD, si_code=CLD_EXITED, si_pid=51, si_uid=0, si_status=0, si_utime=0, si_stime=0} ---
54    +++ exited with 0 +++
53    +++ exited with 0 +++
55    +++ exited with 0 +++
56    +++ exited with 0 +++
52    +++ exited with 0 +++
10    --- SIGCHLD {si_signo=SIGCHLD, si_code=CLD_EXITED, si_pid=52, si_uid=0, si_status=0, si_utime=0, si_stime=0} ---
57    execve("/bin/rm", ["rm", "/tmp/code.go", "/tmp/code"], 0x55ade7799cf0 /* 7 vars */) = 0
57    +++ exited with 0 +++
10    --- SIGCHLD {si_signo=SIGCHLD, si_code=CLD_EXITED, si_pid=57, si_uid=0, si_status=0, si_utime=0, si_stime=0} ---
10    +++ exited with 0 +++