Hitting time statistics and extreme value theory