0
0
Excelspreadsheet~10 mins

SWITCH function in Excel - Interactive Code Practice

Choose your learning style9 modes available
Practice - 5 Tasks
Answer the questions below
1fill in blank
easy

Complete the formula to return "Yes" if A1 equals 1, otherwise "No".

Excel
=SWITCH(A1, 1, [1], "No")
Drag options to blanks, or click blank then click option'
A1
B"No"
CA1
D"Yes"
Attempts:
3 left
💡 Hint
Common Mistakes
Using the wrong return value like "No" instead of "Yes".
Putting the comparison value in the wrong place.
2fill in blank
medium

Complete the formula to return "Red" if B2 is 1, "Blue" if 2, and "Green" if 3.

Excel
=SWITCH(B2, 1, "Red", 2, "Blue", 3, [1], "Unknown")
Drag options to blanks, or click blank then click option'
A"Green"
B"Yellow"
C3
D"Blue"
Attempts:
3 left
💡 Hint
Common Mistakes
Putting the number 3 instead of the color string.
Using the wrong color for 3.
3fill in blank
hard

Fix the error in the formula to return "Small", "Medium", or "Large" based on C3 values 1, 2, or 3.

Excel
=SWITCH(C3, 1, "Small", 2, "Medium", 3, [1])
Drag options to blanks, or click blank then click option'
A"Large"
B"Medium"
C"Small"
D"Extra Large"
Attempts:
3 left
💡 Hint
Common Mistakes
Leaving the last return value blank.
Using the wrong size label.
4fill in blank
hard

Fill both blanks to return "Winter", "Spring", "Summer", or "Fall" based on month number in D4.

Excel
=SWITCH(D4, 12, "Winter", [1], "Spring", [2], "Summer", "Fall")
Drag options to blanks, or click blank then click option'
A3
B6
C9
D11
Attempts:
3 left
💡 Hint
Common Mistakes
Mixing up month numbers for seasons.
Using months out of order.
5fill in blank
hard

Fill all three blanks to return "Low", "Medium", or "High" based on score in E5.

Excel
=SWITCH(E5, [1], "Low", [2], "Medium", [3], "High", "Unknown")
Drag options to blanks, or click blank then click option'
A1
B2
C3
D4
Attempts:
3 left
💡 Hint
Common Mistakes
Using 4 instead of 3 for High.
Mixing up the order of scores.