No. Both the test tube does not contain same quantity of foam. Distilled water taken test tube contains more foam. Soap does not lather well in hard water. The hardness of water is due to dissolved calcium and magnesium salts in it. These salts react with soap to form insoluble compounds resulting in the decrease of lather.