import qualified Data.ByteString.Char8 as B
import qualified Data.IntSet           as S
import           Data.Maybe            (fromJust)

readInts :: B.ByteString -> [Int]
readInts = map (fst . fromJust . B.readInt) . B.words

getInts :: IO [Int]
getInts = readInts <$> B.getLine

main :: IO ()
main = do
  n <- readLn
  as <- getInts
  putStrLn $ if solve n as then "YES" else "NO"

solve :: Int -> [Int] -> Bool
solve n as = S.size (S.fromList as) == n
