You can offer a role of a Kotlin developer to several candidates.
Your company has a special rule written in Kotlin for decision-making.
val offerAJob =
(knowKotlin && yearsOfExperienceInKotlin >= 1) ||
(knowPython && yearsOfExperienceInPython >= 3)A small explanation:
knowKotlinis a boolean variable that shows whether a candidate knows Kotlin.knowPythonis a boolean variable that shows whether a candidate knows Python.yearsOfExperienceInKotlinis an int variable that shows how many years of Kotlin programming a candidate has.yearsOfExperienceInPythonis another int variable that shows how many years of Python programming a candidate has.
Here is our list of candidates with their skills:
John:
knowKotlin=true;yearsOfExperienceInKotlin=1;knowPython=false;yearsOfExperienceInPython=0;
Mary:
knowKotlin=false;yearsOfExperienceInKotlin=0;knowPython=true;yearsOfExperienceInPython=3;
Olivia:
knowKotlin=true;yearsOfExperienceInKotlin=0;knowPython=true;yearsOfExperienceInPython=2;
Alexander:
knowKotlin=true;yearsOfExperienceInKotlin=3;knowPython=true;yearsOfExperienceInPython=2;
Andrew:
knowKotlin=false;yearsOfExperienceInKotlin=1;knowPython=false;yearsOfExperienceInPython=1;
Emily:
knowKotlin=false;yearsOfExperienceInKotlin=0;knowPython=true;yearsOfExperienceInPython=2;
Select all the suitable candidates.
Note that sometimes a candidate may have programming experience but may lack programming language knowledge. Let's consider it a false.