In this work we apply a highly efficient Monte Carlo algorithm recently proposed by Newman and Ziff to treat percolation problems. The site and bond percolations are studied on a number of lattices in two and three dimensions. Quite good results for the wrapping probabilities, correlation length critical exponent, and critical concentration are obtained for the square, simple cubic, hexagonal close packed, and hexagonal lattices by using relatively small systems. We also confirm the universal aspect of the wrapping probabilities regarding site and bond dilution.