hi guy so not sure if I'm asking this question in the right place but trying to learn to code, complete novice, I'm just at the end of the Lear to code 1 in swift playgrounds and I'm stuck on the roll right roll left challange,
if if any one could help me out would really appreciate it,
while isBlockedLeft || isBlockedRight {
moveForward()
if isBlocked && isBlockedRight {
turnLeft()
}
if isBlocked && isBlockedLeft {
turnRight()
}
if isBlocked && !isBlockedRight {
turnLeft()
}
while isOnGem {
collectGem()
}
while isOnClosedSwitch {
toggleSwitch()
}
}
}