feat: classify age into chilhood, teen and adult
This commit is contained in:
@@ -14,3 +14,11 @@ if (age >= 18) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
// Segundo ejercicio:
|
// Segundo ejercicio:
|
||||||
|
|
||||||
|
if (age >= 18) {
|
||||||
|
console.log(name + " es un adulto");
|
||||||
|
} else if (age >= 13) {
|
||||||
|
console.log(name + " es un adolescente");
|
||||||
|
} else {
|
||||||
|
console.log(name + " es un infante");
|
||||||
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user