rephrased some codes