( and ( ( a gas ) ( ( takes ( ( both ( the ( ( shape and ) volume ) ) ) ( of ( its container ) ) ) ) . ) ) )
(ROOT (S (CC and) (NP (DT a) (NN gas)) (VP (VBZ takes) (NP (NP (CC both) (DT the) (NN shape) (CC and) (NN volume)) (PP (IN of) (NP (PRP$ its) (NN container))))) (. .)))
and a gas takes both the shape and volume of its container.
(ROOT (S (NP (DT A) (NN gas)) (VP (VBZ assumes) (NP (NP (DT the) (NN shape)) (PP (IN of) (NP (PRP$ its) (NN container))))) (. .)))