@All..
By quadratic did u mean K*N worst case ?... basically its K*(size of
int generated)...?

On 21 Dec, 22:52, SAMMM <somnath.nit...@gmail.com> wrote:
> Yes Quadratic approach will be naive . I thought initially to take the
> input from the Liveware , and do the below :-
>
> And we will computer for the number of unique number possible for 1
> digit , Let the number of possible distinct permutation be X . And if
> X >= K , then we can generate the single digit number and display the
> kth digits ;
>
> else if ( K > X )  , Calculate the number of possible distinct
> permutation for two digit numbers (with n0 2 digit number starting
> with Zero) (X) and check for the (X<K) . Now generate the 2digit
> possible from the set and print the kth element .
>
> This would be similar to Binary Search if we precompute the number of
> permutation possible for 1digit , 2 digit ... nth digit number . And
> depending on the range of K , we can can generate the digits and print
> the Kth digit ..
>
> Comments are welcome ..
>
> With Regards,
> Somnath Singh
>   NIT DGP

-- 
You received this message because you are subscribed to the Google Groups 
"Algorithm Geeks" group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from this group, send email to 
algogeeks+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/algogeeks?hl=en.

Reply via email to