Created
September 19, 2020 06:46
-
-
Save hassan-maavan/9c43dacc17fee510de1849cc78e7c231 to your computer and use it in GitHub Desktop.
The Western Suburbs Croquet Club has two categories of membership, Senior and Open. They would like your help with an application form that will tell prospective members which category they will be placed. To be a senior, a member must be at least 55 years old and have a handicap greater than 7. In this croquet club, handicaps range from -2 to +…
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function openOrSenior(data){ | |
// ... | |
return data.map(array => array[0] >= 55 && array[1] > 7 ? 'Senior' : 'Open'); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment