Rotated Position of Integers


Please login or register to vote for this query.

(click on this box to dismiss)

Stack Overflow

Q&A for professional and enthusiast programmers

DECLARE @ table(n varchar(9),i int identity(0,1))
INSERT @ VALUES(8),(49),(73),(102),(259),(762),

SELECT-sum(1/~(z*3))FROM(SELECT~i+rank()over(order by
substring(n+n,i%len(n)+1,len(n))*1)z FROM @)c

Enter Parameters

Switch to meta site
loading Hold tight while we fetch your results