Category: Hackerrank

09
Jan
2020

Hackerrank Between Two Sets (C++)

C++ : Explanation: Ok, this one is a nice little challenge on divisors and factors. First, find the largest number in vector a and smallest number in vector b. Next, set the (temporary)...

08
Jan
2020

Hackerrank Kangaroo (C++)

C++ : Explanation: Make jumps (the number of max times the kangaroos can jump) an arbitrarily large number (such as 100,000 as above), then in the while loop, check if starting distance of...

08
Jan
2020

Hackerrank Time Conversion (C++)

C++ : Explanation: Ok, this problem gave quite some headaches with the corner cases of 12PM and 12AM. Had to use some hackos to see the corner cases missed. But first, the general...

07
Jan
2020

Hackerrank Mini-Max Sum (C++)

C++ : Explanation: Using a nested for loop here, the outer loop denotes the number to skip when summing the vector, for the first loop, skip arr[0], then arr[1]… etc. The inner loops...