Informazioni sull’esercizio
Un set di dati di 40 righe su un foglio, una cella di risposta, circa 5 minuti. Correzione nel tuo browser: il valore e la formula che lo produce, con indicazioni su cosa sistemare.
Come risolverlo
- F2
=IF(AND(D2>=4,E2>=12),"Eligible","Not eligible")
AND combines several tests into one: AND(D2>=4,E2>=12) is TRUE only when the rating is at least 4 and the tenure is at least 12 months, and FALSE as soon as either condition fails. Nesting it inside IF turns that TRUE/FALSE into the two labels the policy needs. Filling the formula down applies the same rule to all 40 rows, so the 24 employees who meet only one condition are excluded automatically.
Pitfall 1: AND is a function, not an operator — =IF(D2>=4 AND E2>=12,…) is a syntax error, and =IF(D2>=4,IF(E2>=12,"Eligible","Not eligible"),"Not eligible") works but repeats the else-branch and gets unreadable with a third condition. Pitfall 2: mixing up AND and OR flips the policy; with OR, anyone with 60 months of service would qualify regardless of rating. Pitfall 3: a blank rating compares as 0 and quietly fails the test; decide whether blanks mean "not rated yet" and handle them with IF(D2="",…). Alternatives: =IF((D2>=4)*(E2>=12),…) multiplies the two booleans (1×1 = 1 = TRUE), a pattern you will meet again in SUMPRODUCT; IFS cannot express "both" on its own, so AND stays the right tool. Design: put the thresholds 4 and 12 in cells of their own and reference them with $ so the policy can change without editing formulas; the free-shipping exercise in this track does exactly that.
Altri metodi validi
- =IF(AND(D2>=4,E2>=12),"Eligible","Not eligible") — reference solution
- =IF((D2>=4)*(E2>=12)=1,"Eligible","Not eligible") — booleans multiplied instead of AND (accepted by the value check, but this task asks for AND)
- =IF(OR(D2<4,E2<12),"Not eligible","Eligible") — the same rule stated through its failures
Errori comuni
Using OR instead of AND, so an employee with a rating of 3 and 60 months of service shows Eligible — the grader points at that row because only one of the two conditions holds there.
Come valutiamo
È accettata qualsiasi formula che produce il risultato giusto, a meno che l’attività non indichi una funzione: in quel caso un’altra funzione vale metà dei punti. Confrontiamo i valori con una piccola tolleranza e ignoriamo maiuscole, minuscole e spazi nel testo. Un numero corretto digitato a mano invece di una formula vale metà dei punti. Le attività su più celle valgono il punteggio pieno con il 100% delle celle giuste, metà dei punti dal 50%. Dove serve, cambiamo anche una cella di input su una copia del tuo foglio e controlliamo che la formula si aggiorni.
Risposte calcolate con le regole di Excel 365 e verificate nel nostro correttore in data 16 novembre 2026. Autore: GridBelt team.