Practice - 5 Tasks
Answer the questions below
1fill in blank
easyComplete the code to subscribe to a Redis channel named 'news'.
Redis
SUBSCRIBE [1] Drag options to blanks, or click blank then click option'
Attempts:
3 left
💡 Hint
Common Mistakes
Using quotes around the channel name like 'news'.
Using a different channel name than 'news'.
✗ Incorrect
The SUBSCRIBE command takes the channel name without quotes. So, SUBSCRIBE news is correct.
2fill in blank
mediumComplete the code to subscribe to two Redis channels named 'sports' and 'weather'.
Redis
SUBSCRIBE [1] [2]
Drag options to blanks, or click blank then click option'
Attempts:
3 left
💡 Hint
Common Mistakes
Adding quotes around channel names.
Using commas between channel names.
✗ Incorrect
SUBSCRIBE command accepts multiple channel names without quotes. So, SUBSCRIBE sports weather is correct.
3fill in blank
hardFix the error in the code to subscribe to the channel 'alerts'.
Redis
SUBSCRIBE [1] Drag options to blanks, or click blank then click option'
Attempts:
3 left
💡 Hint
Common Mistakes
Using quotes around the channel name.
Using wrong case or misspelled channel name.
✗ Incorrect
Channel names are case-sensitive and should not be quoted. SUBSCRIBE alerts is correct.
4fill in blank
hardFill both blanks to subscribe to channels 'news' and 'updates'.
Redis
SUBSCRIBE [1] [2]
Drag options to blanks, or click blank then click option'
Attempts:
3 left
💡 Hint
Common Mistakes
Using quotes around channel names.
Separating channel names with commas.
✗ Incorrect
SUBSCRIBE command requires channel names without quotes separated by space.
5fill in blank
hardFill all three blanks to subscribe to channels 'chat', 'alerts', and 'news'.
Redis
SUBSCRIBE [1] [2] [3]
Drag options to blanks, or click blank then click option'
Attempts:
3 left
💡 Hint
Common Mistakes
Using quotes around channel names.
Using wrong channel names or misspellings.
✗ Incorrect
SUBSCRIBE command takes multiple channel names without quotes separated by spaces.