s//123 456 7890147,258,369,159,357/;$?=/(.)\1\1/?die$1:/\d/?<>:die(Tie)while!s/$?/$:/g||print$`x/-/,$:=$:^h?X:O