Is there a better approach to this problem?
I created 4 BITs, one to process count of bombs, the sum of coordinates, the count of coordinates, and the product of coordinates and bombs. Here is my code http://p.ip.fi/VjK6
Please suggest if a better approach exists.
A better approach?
@wandan23 hey,use combinatorics and bit will be use to teell how many small numbers are there till that time which are inserted , so inserting and calculating together.Slight modification from your code,see this code,also your logic is correct:
I hope I’ve cleared your doubt. I ask you to please rate your experience here
Your feedback is very important. It helps us improve our platform and hence provide you
the learning experience you deserve.
On the off chance, you still have some questions or not find the answers satisfactory, you may reopen
the doubt.