Sequence A[n] of natural numbers from 1 to M is ordered ascending the maximum number obtained from binary representation of a sequence member under cyclic shift preserving the number of digits (the larger umber has the larger ordinal number for two equal maximum numbers). For example the binary representation for the number 19 will be 10011. The options obtained after cyclic shift will have the following representation:
.
And the maximum number is 28. Thus the sequencing key for number 19 will be 28, the sequencing key for the number say, 1025 will be 1536, etc.
For M=2000 in the position with ordinal number 1234 of the ordered sequence there is the following cardinal number …