about | help | code help+videos | done | prefs |
logic_squarePossible
Given one integer "oneFooters" and another integer "fiveFooters", where those represent how many 1' and 5' pieces of wood that you have, return true if it is possible to lay them all on the ground and create a square. Example: If you have fifteen 1' pieces and one 5' piece, you can create a square where each side has a length of 5'. Note: You must use all of the pieces of wood! logic_squarePossible(3, 3) → false logic_squarePossible(13, 5) → false logic_squarePossible(14, 5) → false ...Save, Compile, Run (ctrl-enter) |
Progress graphs:
Your progress graph for this problem
Random user progress graph for this problem
Random Epic Progress Graph
Copyright Nick Parlante 2017 - privacy