this is my first post and I hope its succinct and relevant enough to post here.
I'm working on finding the largest number in a multiplication table (n by n) that satisfies a certain property. In finding the largest number, I realize that you can just sort the elements in the table, or get a bit smarter and do something like a saddle back search, checking each element for your property in order.
However, I was wondering if there was a way to sort the elements in a multiplication table in constant time, as with a pen and a pencil it seems that there is some sort of pattern.
Thanks!