main :: IO () main = do input <- getLine let result = fst . head . filter (\(a, b) -> a /= read b) . zip [1..] $ words input putStrLn . show $ result