Malik uses pennies to make three consecutive perfect squares.He uses 13 more pennies for the second square than for the first. Next he uses 15 more pennies for the third square than for the second. What is the total number of pennies he used to make three squares?