Skip to content

Instantly share code, notes, and snippets.

@TechandEco
Last active January 7, 2020 18:22
Show Gist options
  • Save TechandEco/f4a4549b3c951489d8832167521af5df to your computer and use it in GitHub Desktop.
Save TechandEco/f4a4549b3c951489d8832167521af5df to your computer and use it in GitHub Desktop.
GSuite-samples/room_capacity/Code.js
/**
* Assigns a type of room needed for a session based on its number of
* registered participants.
*
* @param {number} numParticipants - number of participants.
*
* @returns {string} - size of room.
*/
function ROOM_TYPE(numParticipants) {
if (numParticipants <= 25) {
return '🎈 Medium room: 25max';
}
if (numParticipants <= 40) {
return 'πŸŽ‰ Large room: 40max';
}
return 'πŸ’₯ Extra-large room: 200max'
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment