A pipe can fill a tank in 12 hours and another pipe can empty it in 18 hours.If both are opened simultaneously, in how many hours will the tank be filled?