Hi
how about finding this for an integer array and finding i and j such that
Min(j-i)
surender
On Fri, Dec 2, 2011 at 3:09 AM, sravanreddy001 sravanreddy...@gmail.comwrote:
An idea is to start with a heap of size k.
Its tricky how to keep track of the start and end indices of the smallest
Thanks. I got it...
On Fri, Dec 2, 2011 at 12:30 PM, atul anand atul.87fri...@gmail.com wrote:
simple way of understanding this algo is that , q is incremented twice
than p or you can say q is moving twice faster then p.
consider a scenario where last_node- = first_node.
now q would
@Karthikeyan:
I want linear time solution not nlogn
On 1 December 2011 23:42, Karthikeyan V.B kartmu...@gmail.com wrote:
Hi,
Create a binary search tree with elements , while inserting check for
equal elements and delete it.
But for insertion of n elements in a BST takes O(nlogn)
--
parse the document for the words and maintain a position table
position table should be like this:
w1- p1 p2 p3pn
w2-x1 x2 x3 xn
k lists
O(n) if hashing is used
now go to begining of list and findout the maximum position say
'start' O(k)
similarly from end of all list , check for the
@Kumar: What makes you think that there is an O(n) time, O(1) space
algorithm?
Dave
On Dec 2, 6:26 am, kumar raja rajkumar.cs...@gmail.com wrote:
@Karthikeyan:
I want linear time solution not nlogn
On 1 December 2011 23:42, Karthikeyan V.B kartmu...@gmail.com wrote:
Hi,
Create a
@Sravanreddy: Filling in a few details:
Find the first occurrence of each given word in the document. While
doing this, insert the location of each word into a min-heap, and keep
track of the maximum of all locations. Record the difference between
the top of the heap and the maximum as the
Hi,
I got selected in Microsoft yesterday. Thanks to all the geeks and
the group, especially to managers!!! My concept regarding the logic
for Algorithms and how the tackle a new problem have been improved
after seeing many post and solutions from different people, so that
credit goes to this
congrats :) :)
On Fri, Dec 2, 2011 at 8:39 PM, VIHARRI viharri@gmail.com wrote:
Hi,
I got selected in Microsoft yesterday. Thanks to all the geeks and
the group, especially to managers!!! My concept regarding the logic
for Algorithms and how the tackle a new problem have been improved
Congratulations:)
--
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
gr8...congrats dude
On Fri, Dec 2, 2011 at 9:05 PM, Karthikeyan V.B kartmu...@gmail.com wrote:
Congratulations:)
--
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
plz post how you prepared for MS..like the books or websites you
followedwould b of gr8 help.
On Fri, Dec 2, 2011 at 9:42 PM, rahul sharma rahul23111...@gmail.comwrote:
gr8...congrats dude
On Fri, Dec 2, 2011 at 9:05 PM, Karthikeyan V.B kartmu...@gmail.comwrote:
Congratulations:)
congrats..:):)
plzz...elaborate the last two problemsand it vud be very grateful
if u tell their solns tooo...
Regards,
payal gupta,
cse,3rd year,
nit-b.
On 12/2/11, rahul sharma rahul23111...@gmail.com wrote:
plz post how you prepared for MS..like the books or websites you
(!x || !(x^1))
!(x1)
!((x|1)-1)
(x*x)==x
(x==(x==x))||(x==(x!=x))
etc.
On Nov 29, 9:07 pm, Nitin Garg nitin.garg.i...@gmail.com wrote:
*What are the different ways to say, the value of x can be either a 0 or a
1.*
--
Nitin Garg
Personality can open doors, but only Character can keep them
Hi,
Here is my problem:
I have a list of items (only positive integers are allowed) and fixed
number of bins of identical capacity. I need to pack items (if
possible) so that elements in each bin sum up to given capacity.
So far I implemented recursive algorithm but I try to convert my
recursive
14 matches
Mail list logo