- Prepare
- Algorithms
- Warmup
- A Very Big Sum
- Discussions
A Very Big Sum
A Very Big Sum
+ 21 comments I don't think that this problem needs to exist because it's redundant with the simple array sum challenge. All I did was change
sum
's type fromint
tolong
in Java, and the challenge even told me how.
+ 4 comments For people posting their codes, hit enter and tab the first line so it would look coherent.
{ CODE Like this }
{ not like
this}
+ 8 comments My python 3 solution:
def aVeryBigSum(ar): res = 0 for i in range(len(ar)): res += ar[i] return res
+ 0 comments One thing is there is similar "challenge" already, although in this case number may be large, that's fine. It is EASY, but why would you give solver a hint about using specific type? Isn't it a point of a challange to find out for yourself that you need to use type that can hold large number? By revealing this in note, solving it is pointless. And this plagues many of the challenges here. Why give solver all the necessary hints right away is beyond me.
+ 2 comments I'm new to HackerRank--why is there already code in the solution window? Shouldn't we be coding things from scratch?
Sort 1474 Discussions, By:
Please Login in order to post a comment