about | help | code help+videos | done | prefs |
commonDigit
Define a function that when passed two integers, returns true if they have any digit in common, false otherwise. Note: Zero by itself does not contain any digit. So return false if either value is 0. commonDigit(1729, 234) → true commonDigit(12345, 54321) → true commonDigit(12345, 67890) → 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
Difficulty: 4 Post-solution available
Copyright Nick Parlante 2017 - privacy