“2D Arrays – DS” Walkthrough – HackerRank Solutions

This video walks through designing and implementing an efficient solution to 2D Arrays – DS on HackerRank.

View the original problem here:


“Clean Code” by Robert C. Martin:
“Game Coding Complete” by Mike McShaffry:
“JavaScript and JQuery” by Jon Ducket:


Creating, updating and managing DevFactor’s large collection of tutorials requires many hours of work on a weekly basis. If you have found our tutorials useful, please support us by subscribing and sharing our videos on social media.

If you have any feedback in regards to how we could improve the channel’s content, editing, or organization feel free to get in touch and make a suggestion!

Subscribe on YouTube:


DevFactor offers high-quality, project based tutorials on web development, game development and software engineering. Simply by subscribing you can gain access to our large library of free programming video tutorials.

DevFactor was started in order to aid anyone regardless of age, race, gender or location to learn how to build, maintain and deploy their own software applications.

#programming #code #devfactor






6 responses to ““2D Arrays – DS” Walkthrough – HackerRank Solutions”

  1. Diaz Agasatya Avatar

    should the middle row of the hourglass be [ k = 2 ]? it's looking for the second int in row two which is column 2 right? correct me if i'm wrong. thanks!

  2. Keira Perez Avatar

    For the temp array values, why use i<4 instead of i<3? I run it separately but i only noticed that in i<3, it skips the second row for the hourglass array… hoping for quick reply, i'm still a beginner 🙂

  3. BhavaniSankar Nakka Avatar

    in the second for loop i tried to give for(int i= 0; i<6;i++)…..
    it is throwing ArrayIndex…..Bounds Exception. but if i change it to for(int i= 0; i<4;i++) ….
    it is executing . May i know the why it is not working with 6?

  4. nmk kannan Avatar

    Hi dude, your video is awesome. Is practising hacker rank would improve my skills on DS and Algorithms?

  5. YaBoy Prince. Avatar

    Hey Do You Have Twitter ?

  6. Aspect Avatar

    will you ever start doing C++ videos? 😀

Leave a Reply

Your email address will not be published. Required fields are marked *