Statistics of the work done by splitting a one-dimensional quasi-condensate