Random commentary about Machine Learning, BigData, Spark, Deep Learning, C++, STL, Boost, Perl, Python, Algorithms, Problem Solving and Web Search
actually only a couple of bytes are neededlong long c = 0;for each number in the collection c += numberreturn (1+360m)/2*360m - c
actually only a couple of bytes are needed
ReplyDeletelong long c = 0;
for each number in the collection
c += number
return (1+360m)/2*360m - c