Ad
  • Default User Avatar

    I could've added a and b into one variable to make the code more compact

  • Default User Avatar

    While it's short, what would happen if someone goes beyond inserting 12? It will return a number and create more quadrants. It might be the tidiest, shortest or even the fastest and it's quite enough for the exercise/instructions at hand, but the solution above seems to be more grounded to me.
    But at the end of the day I'm just a beginner.