What does "order an array" mean, either by rows or columns?

1

What does "order an array" mean, either by rows or columns?

    
asked by anonymous 04.07.2018 / 05:47

1 answer

3

Probably a wrong way to say "classify each element of a row or column of an array". See What is the difference between ordered, unordered and sorted? . Everyone says it wrong. In order it is already, it is not classified. You can not order something that already has an order. In English you would say sorting the matrix , would not say ordering the matrix .

Then you take a sequence of values, probably numbers, which is in an order any analyzes each, will bring to the beginning of the lowest values, and will sending to the end of the highest values, so at the end of each element next one will always be bigger than the previous one, seno the first one smaller of all and the last one the greater one of all. It is also possible to sort descendingly and the first is the largest and the last is the smallest.

If it is not numbers the classification to be lexicographic, ie popularly alphabetically. If it is another data type you have to determine how it ranks.

One thing that can happen is to use more than one element as a criterion, then would have to adopt a criterion can be only looking at the first element of the row or column, the sum, or something else.

    
04.07.2018 / 05:57