-
Notifications
You must be signed in to change notification settings - Fork 593
Description
In the "Logic" lesson of the R Programming course, beginners course, swirl asks the user to type:
TRUE && c(TRUE, FALSE, FALSE)
Error in TRUE && c(TRUE, FALSE, FALSE) :
'length = 3' in coercion to 'logical(1)'
As a result, users cannot continue the lesson. Using skip() does not work — swirl exits and when restarted, the same question is asked again.
Steps to Reproduce:
Open RStudio with R version 4.5
Load swirl:
library(swirl)
Start the R Programming course and navigate to the "Logic" lesson.
At the step asking to type TRUE && c(TRUE, FALSE, FALSE), enter the expression.
Observe the error and swirl exiting.
Expected Behavior:
Swirl should accept the expression in a way compatible with R ≥ 4.3 / 4.5, or
Update the lesson to use a safe example, e.g.:
TRUE && TRUE
This demonstrates the && behavior without causing an error.
Additional Information:
R version: R version 4.5.1 (2025-06-13 ucrt)
OS: Windows
Behavior: skip() does not move past the question; restarting swirl returns to the same broken step.