CodeHS Answers: Unit 3 : Super Karel
and For Loops 2025/2026 Exam All
Answers and Illustrations Given
What is a code comment? - 🧠 ANSWER ✔✔A way to give notes to the
reader to explain what your code is doing
3.1.3: Hurdle Karel - 🧠 ANSWER ✔✔/*
* This program has karel jump over two
* hurdles and then move all of the way
* to the edge of the world.
*/
function start(){
// Karel jumps two hurdles in this
// program.
runToHurdle();
jumpHurdle();
COPYRIGHT©NINJANERD 2025/2026. YEAR PUBLISHED 2025. COMPANY REGISTRATION NUMBER: 619652435. TERMS OF USE. PRIVACY
1
STATEMENT. ALL RIGHTS RESERVED
,runToHurdle();
jumpHurdle();
runToFinish();
}
/*
* Precondition: Karel has just jumped the
* last hurdle, and is facing east.
* Postcondition: Karel is all of the way
* at the end of the world.
*/
function runToFinish(){
move();
move();
move();
move();
}
COPYRIGHT©NINJANERD 2025/2026. YEAR PUBLISHED 2025. COMPANY REGISTRATION NUMBER: 619652435. TERMS OF USE. PRIVACY
2
STATEMENT. ALL RIGHTS RESERVED
, /*
* Precondition: Karel is facing east, three
* spots away from a hurdle.
* Postcondition: Karel is standing right in * front of a hurdle.
*/
function runToHurdle(){
move();
move();
move();
}
/*
* This function has karel jump over a
* hurdle that is one row high.
* Precondition: Karel is standing in front
* of a hurdle, facing east.
* Postcondition: Karel has just jumped over
COPYRIGHT©NINJANERD 2025/2026. YEAR PUBLISHED 2025. COMPANY REGISTRATION NUMBER: 619652435. TERMS OF USE. PRIVACY
3
STATEMENT. ALL RIGHTS RESERVED
and For Loops 2025/2026 Exam All
Answers and Illustrations Given
What is a code comment? - 🧠 ANSWER ✔✔A way to give notes to the
reader to explain what your code is doing
3.1.3: Hurdle Karel - 🧠 ANSWER ✔✔/*
* This program has karel jump over two
* hurdles and then move all of the way
* to the edge of the world.
*/
function start(){
// Karel jumps two hurdles in this
// program.
runToHurdle();
jumpHurdle();
COPYRIGHT©NINJANERD 2025/2026. YEAR PUBLISHED 2025. COMPANY REGISTRATION NUMBER: 619652435. TERMS OF USE. PRIVACY
1
STATEMENT. ALL RIGHTS RESERVED
,runToHurdle();
jumpHurdle();
runToFinish();
}
/*
* Precondition: Karel has just jumped the
* last hurdle, and is facing east.
* Postcondition: Karel is all of the way
* at the end of the world.
*/
function runToFinish(){
move();
move();
move();
move();
}
COPYRIGHT©NINJANERD 2025/2026. YEAR PUBLISHED 2025. COMPANY REGISTRATION NUMBER: 619652435. TERMS OF USE. PRIVACY
2
STATEMENT. ALL RIGHTS RESERVED
, /*
* Precondition: Karel is facing east, three
* spots away from a hurdle.
* Postcondition: Karel is standing right in * front of a hurdle.
*/
function runToHurdle(){
move();
move();
move();
}
/*
* This function has karel jump over a
* hurdle that is one row high.
* Precondition: Karel is standing in front
* of a hurdle, facing east.
* Postcondition: Karel has just jumped over
COPYRIGHT©NINJANERD 2025/2026. YEAR PUBLISHED 2025. COMPANY REGISTRATION NUMBER: 619652435. TERMS OF USE. PRIVACY
3
STATEMENT. ALL RIGHTS RESERVED