' Name: Sort.Swap ' ' Headline: Swaps two elements of a list ' ' Self: {X, i,j}; X: List; i,j: Integer 0..X.Count-1 ' ' Called by: ' ' Returns: ' ' Description: ' ' Topics: ' ' Search Keys: ' ' Requires: ' ' History: J. Bentley, Programming Pearls ' ' Comments: '=============================================================================' X = SELF.Get(0) i = SELF.Get(1) j = SELF.Get(2) temp = X.Get(i) X.Set(i, X.Get(j)) X.Set(j, temp) ' end of script