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 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 [email protected]. To unsubscribe from this group, send email to [email protected]. For more options, visit this group at http://groups.google.com/group/algogeeks?hl=en.
