now we need to select 2 indexes such that the diff array i greater or
equal to [1,1,1,1]

How do you do that?

It is an O(n^2) algorithm right?

Can you do it better like O(nlogn)

where n is number of words in a given sentence.



-- 
With love and regards,
Sairam Ravu
I M.Tech(CS)
Sri Sathya Sai Institute of Higher Learning
"To live life, you must think it, measure it, experiment with it,
dance it, paint it, draw it, and calculate it"

-- 


Reply via email to