Value iteration for simple stochastic games: Stopping criterion and learning algorithm