[algogeeks] Re: Array Problem??

2011-10-03 Thread Abraham
Hi Vikram! Obviously The naivest solution is O(n2). Could you give a hint for this problem? On Oct 3, 4:39 pm, Vikram Singh singhvikram...@gmail.com wrote: Given an array say A=(4,3,1,2). An array B is formed out of this in such a way that B[i] = no. of elements in A, occuring on rhs of A[i],

[algogeeks] Re: Amazon - array problem

2011-09-30 Thread Abraham
Can we replace the operator (/) with 1^(-n) ? On Sep 30, 12:54 pm, raju nikutel...@gmail.com wrote: @nitin .. Output array is not a new array ... you can do anything to input array .. ~raju On Fri, Sep 30, 2011 at 1:24 PM, Nitin Garg nitin.garg.i...@gmail.comwrote: Can we assume