Skip to content

Instantly share code, notes, and snippets.

@terrehbyte
Last active September 17, 2019 21:36
Show Gist options
  • Save terrehbyte/a9a036c75816a5f7d9f28c4411368d4c to your computer and use it in GitHub Desktop.
Save terrehbyte/a9a036c75816a5f7d9f28c4411368d4c to your computer and use it in GitHub Desktop.

Whiteboard Exercise

In groups, complete the following exercises on a whiteboard with help from your team. Once you think you have a working solution, have someone from the team transcribe it into the HackerRank editor and test to see if it works. If it fails one of the test cases, review it as a team and return to the whiteboard to edit your solution.

Work through the following exercises. They are provided in the order from least difficult to most difficult according to HackerRank's system.

Tips

  • Think before you program. You're designing a system.
    • You can try to break the problem down into discrete and smaller chunks that might be easier to think about.
  • Identify the scope of the exercise. What are you supposed to do?
  • Create a test input to work with. One is often provided as a part of the problem.
  • Don't worry about the syntax too much; it's a whiteboard, not a compiler.
  • Do a dry-run of your code. Work through it aloud or on the whiteboard.
  • Try to think of situations that will break your code.
    • Are there any potential inputs that it can't handle that might be provided?
  • Make sure that everyone understands how the problem is being solved.
    • There's no point if you're just along for the ride.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment