Time taken for the tank holding 268 gallons to empty will be:
time=volume/rate=268/3 weeks
Time taken for the tank holding 402 gallons to empty:
time=402/5
the number of weeks required for the amount of water to be the same will be found by calculate the LCM of the time taken by both tanks to empty. This will be:
LCM[402/5,268/3]
=7182 2/5 weeks