Say you have array that is 10x3 (e.g. Each X is Y0 = Apple, Y1 = Food, Y2 = £5... And then 8 other foods in the array).
Have your array be 10x4 instead, and the first Y0 is now a number (then Y1 = Apple, Y2 = Food, etc).
For each X, set Y0 to random number.
Sort via X.
Random shuffle that keeps relationship!
... I think, just guessing.