For Loops in Python to iterate over id for each item in column : I want to iterate over a dataframe so for each id and for each fruit, so that for each fruit there is a the other fruits associated with that id and the prices of both.

[example and expected results][1]


  [1]: https://i.stack.imgur.com/6Fvhh.png