Modifying the PercolationStats code