next row:
3 1 2 2 1 1
just read the previous row: THREE 1 TWO 2 ONE 1
Regards,
Akash Agrawal
http://tech-queries.blogspot.com/
On Wed, Apr 13, 2011 at 3:27 PM, vaibhav shukla vaibhav200...@gmail.comwrote:
On Wed, Apr 13, 2011 at 1:02 PM, Lavesh Rawat lavesh.ra...@gmail.comwrote
a bit more clearly ??
On Apr 13, 3:27 pm, Akash Agrawal akash.agrawa...@gmail.com wrote:
next row:
3 1 2 2 1 1
just read the previous row: THREE 1 TWO 2 ONE 1
Regards,
Akash Agrawalhttp://tech-queries.blogspot.com/
On Wed, Apr 13, 2011 at 3:27 PM, vaibhav shukla
vaibhav200...@gmail.comwrote
Given an array with two subparts sorted. How will you make a final sorted
array.
i/p: 1, 5, 7, 9, 11, 23, 2, 3, 8, 9, 21
o/p:
1, 2, 3, 5, 7, 8, 9, 9, 11, 21, 23
Regards,
Akash Agrawal
http://tech-queries.blogspot.com/
--
You received this message because you are subscribed to the Google
This is obvious solution what if u have contant space?
Regards,
Akash Agrawal
http://tech-queries.blogspot.com/
On Tue, Apr 12, 2011 at 3:48 PM, rajul jain rajuljain...@gmail.com wrote:
use merge sort
On Tue, Apr 12, 2011 at 3:07 PM, Akash Agrawal
akash.agrawa...@gmail.comwrote:
Given
, 9, 21
1, 2, 3, 5, 11, 9, 7, 8, 9, 21
1, 2, 3, 5, 7, 9, 11, 8, 9, 21
1, 2, 3, 5, 7, 8, 11, 9, 9, 21
1, 2, 3, 5, 7, 8, 9, 11, 9, 21
1, 2, 3, 5, 7, 8, 9, 9, 11, 21
Regards,
Akash Agrawal
http://tech-queries.blogspot.com/
On Tue, Apr 12, 2011 at 10:23 PM, powerideas
arpitbhatnagarm
throw opposite to gravity...
Regards,
Akash Agrawal
http://tech-queries.blogspot.com/
On Wed, Apr 6, 2011 at 1:26 PM, balaji a peshwa.bal...@gmail.com wrote:
when u throw it above u.
On Wed, Apr 6, 2011 at 1:16 PM, Lavesh Rawat lavesh.ra...@gmail.comwrote:
* The Ball Puzzle
*How can
14
Regards,
Akash Agrawal
http://tech-queries.blogspot.com/
On Tue, Apr 5, 2011 at 1:17 PM, DeboJeet Choudhury
wildrahul.on...@gmail.com wrote:
34 roses @ the begining...
On Tue, Apr 5, 2011 at 1:11 PM, Lavesh Rawat lavesh.ra...@gmail.comwrote:
*Roses Puzzle Solution*
*
*I have
7 races...
Regards,
Akash Agrawal
http://tech-queries.blogspot.com/
On Mon, Mar 28, 2011 at 3:50 PM, anand karthik
anandkarthik@gmail.comwrote:
Evertime you conduct a race, you eliminate 2 horses. So, 11.
On Mar 28, 2011 1:24 PM, Lavesh Rawat lavesh.ra...@gmail.com wrote:
*Horse Race
http://tech-queries.blogspot.com/2009/05/find-largest-20-elements-from-billions.html
Regards,
Akash Agrawal
http://tech-queries.blogspot.com/
On Tue, Mar 22, 2011 at 10:13 AM, Rajeev Kumar rajeevprasa...@gmail.comwrote:
http://flexaired.blogspot.com/2011/03/big-file-containing-billions
shadow...
Regards,
Akash Agrawal
http://tech-queries.blogspot.com/
On Mon, Mar 14, 2011 at 1:57 PM, Praveen praveen200...@gmail.com wrote:
Wood
On Mon, Mar 14, 2011 at 1:45 PM, Lavesh Rawat lavesh.ra...@gmail.comwrote:
*
Riddle Problem Solution*
**
*
*The part of the bird
U can always have a trackback array as we do in LIS.
Regards,
Akash Agrawal
http://tech-queries.blogspot.com/
On Fri, Mar 4, 2011 at 5:48 PM, Vipin Agrawal vipin.iitr@gmail.comwrote:
Solution is good, but its says only Max time that he can spend.
How would he know that which program he
])
{
ans[i] = cos;
// cout ans[i]iendl;
}
}
}
if (i=140 ans[i] INT_MAX)
break;
}
cout ans[i] i endl;
return 0;
}
Regards,
Akash Agrawal
http://tech-queries.blogspot.com/
On Thu, Dec 30, 2010 at 6:03 PM, juver++ avpostni...@gmail.com wrote:
DP[K][N] - minimal cost choosing N
http://tech-queries.blogspot.com/2010/12/finding-minimum-window-in-array-which.html
just use words in place of chars...
Regards,
Akash Agrawal
http://tech-queries.blogspot.com/
On Fri, Dec 31, 2010 at 11:00 AM, Davin dkthar...@googlemail.com wrote:
Find the area with less distance between
packets of 70 balls each to minimize
cost.
Regards,
Akash Agrawal
http://tech-queries.blogspot.com/
--
You received this message because you are subscribed to the Google Groups
Algorithm Geeks group.
To post to this group, send email to algoge...@googlegroups.com.
To unsubscribe from this group, send
http://tech-queries.blogspot.com/2010/12/find-pythagorean-triples-in-unsorted.html
Regards,
Akash Agrawal
http://tech-queries.blogspot.com/
On Mon, Dec 20, 2010 at 8:12 PM, Dave dave_and_da...@juno.com wrote:
Unless sorting the array is forbidden, sort it and then use the
obvious O(n^2
2D matrix sum is a simple DP problem, but U need n*n extra space as well or
have to change the i/p.
(u can get the i/p back once if required)
If this is acceptable, let me explain.
Regards,
Akash Agrawal
http://tech-queries.blogspot.com/
On Sun, Dec 19, 2010 at 7:01 PM, juver++ avpostni
Hey Amir,
Can u please throw some more light on this. I am not able to find a good
solution for subset sum problem as well.
Regards,
Akash Agrawal
http://tech-queries.blogspot.com/
On Fri, Dec 17, 2010 at 7:29 PM, Amir hossein Shahriari
amir.hossein.shahri...@gmail.com wrote:
sort jewelries
) 5 (first
5) 1,2,3,4
5,5Note that each '5' is a different piece of jewelry and needs to be
accounted for separately. There are 9 legal ways of allocating the jewelry
to Bob andFrank given the policy, so your method would return 9.
Regards,
Akash Agrawal
http://tech-queries.blogspot.com
use FILE *
Can u elaborate on the probelm?
Regards,
Akash Agrawal
http://tech-queries.blogspot.com/
On Mon, Dec 13, 2010 at 1:03 PM, neeraj agarwal
itsneerajagar...@gmail.comwrote:
i am facing problem in file handling in C
can any one suggest me how to implement them.
--
You received
It is like finding the in order successor.
See it here (using parent pointer)
http://tech-queries.blogspot.com/2010/04/inorder-succesor-in-binary-tree.html
w/0 Parent pointer:
http://tech-queries.blogspot.com/2010/04/inorder-succesor-in-binary-tree-wo.html
Regards,
Akash Agrawal
http://tech
You have given a matrix of n*m integer. A query will come to you with two
co-ordinate (x1,y1) (x2,y2). You need to find sum of all elements which
falls inside rectangle. As you will be bombarded with such query, you
solution should be very very quick.
Ans should be in O(1)
Regards,
Akash
Thanks everyone; that O(n^2) is an awesome solution.
Regards,
Akash Agrawal
http://tech-queries.blogspot.com/
On Thu, Dec 2, 2010 at 12:21 PM, fenghuang fenghaungyuyi...@gmail.comwrote:
@anoop
when you find some i and j(i j) meet the condition i.e. asq[i] + asq[j]
== asq[k], you can merge
22 matches
Mail list logo