Questions tagged [karel]

Karel is an introductory programming language in which one controls a simulated robot.

Karel is an introductory programming language designed by Richard Prattis in 1981 at Stanford University in order to teach basic programming syntax and operations.

Additional libraries and languages have been built based on Karel, including Karel++ and becker.robots for Java to more accurately cover object-oriented programming syntax.

45 questions
0
votes
1 answer

Why does the robot in Karel not stop even if he stands on a beeper?

I am trying to solve the problem (2.4.1, SolveTheMaze) but for some reason, the robot doesn't stop when he's on a beeper - he just keeps going. It seems like I have created an infinite loop. Here's a picture of the problem: Karel: SolveTheMaze Here…
tknew
  • 1
0
votes
1 answer

(Roboguide) Fanuc Karel Socket Messaging MSG_CONNECT error with status -1736775297

In Roboguide, when I try to connect to a server by calling MSG_CONNECT it can give a status of -1736775297. Which is not very helpful, since Karel suppose to give 5 digit positive integer error code.
Tedy Pranolo
  • 1,285
  • 1
  • 14
  • 22
0
votes
1 answer

How to execute 'for i in range' loop twice?

I am trying to make Karel pick three batches of beepers each consisting of ten beepers. I want 'move_batch()' to be called twice but it is executed 3 times because of the first 'for i in range(3):' command. When Karel moves 3 times, it meets the…
Narmin
  • 11
  • 3
0
votes
2 answers

Trying to come up to loop through a for loop unless the "i" is on an excluision list

I am writing a program in Karel, which is basically Pascal plus motion commands for Fanuc robots. My code works, including looping through it 200 times with a for loop. Now I want to add an exclusion list so in pseudocode" "for I=1 to 200 do unless…
DeucesAx
  • 3
  • 1
0
votes
0 answers

Cannot resolve symbol "CollectNewspaperKarel"

I've been trying to make CS106A work on my computer for ages, and it seems that I am missing out on a huge part of my Java education, because I keep on hearing stuff about dependencies, and classpaths, and have entered in too many lines into cmd…
0
votes
1 answer

constructor error creating new Karel right turn robot

I'm new to java and trying to create a new robot class with a method for Karel to turn right. However, when I try and extend the class "RightTurnerRobot" to include "Robot", I get the following error: Implicit super constructor Robot() is undefined…
J. Doe
  • 11
  • 1
  • 3
0
votes
1 answer

Functions nesting

I'm taking the online course "Programming Methodology" available on iTunes U. The course has an introduction with "Karel the robot" based on Java and it raised a question for me. Take for example this code : import stanford.karel.*; public class…
Sar
  • 129
  • 4
0
votes
2 answers

Becker Robots: Getting them to move

So I have to use the becker.robots package to move forward and pick up a certain amount of flashers and then turn around and place them. However, I am not sure how to invoke the robot.move() method. Everytime I try to make it move forward I get a…
0
votes
2 answers

How to create an overarching if statement? As in, "if this happens at any point in the program..."

my assignment is to create an algorithm for the karel robot to use to exit a maze and stop once it reaches a beeper. I have successfully created this algorithm except for getting karel to stop when it reaches the beeper. This is only a portion of my…
Sam
  • 43
  • 5
0
votes
1 answer

Karel Robot: Cannot find symbol

Throughout a maze, I am trying to have my robot put a thing down(putThing) every intersection where one is not already at. RobotSE has the boolean method, isBesideThing(), which I am attempting to use. However, I keep getting the compiling…
Leif
  • 125
  • 9
0
votes
1 answer

Eclipse won't start to run Stanford karel

I am a beginner in programming and I decided to take the Stanford online Intro to Programming Methodology course (cs106a). I followed the instructions and unzipped the Eclipse files onto my computer. When I tried to open it, it said "An error has…
BlakJack
  • 11
  • 1
0
votes
1 answer

serial Version of Karel

I recently started to learn about Programming through iTunes U, in CS106A at Stanford through the videos. And I am now working with Karel or so to write. I followed the instructions about downloading everything to the letter but when I start to…
-1
votes
1 answer

(ROBOGUIDE) Fanuc Karel Stack Overflow error

When running a karel program in roboguide a stack overflow error occurs, even though there is no recursion. There is no other information given by roboguide.
Tedy Pranolo
  • 1,285
  • 1
  • 14
  • 22
-1
votes
1 answer

How to fix a NullPointerException error when running a program with becker.jar as an external jar?

I am setting up a program for a class I am taking. All the code has been provided and I have configured everything into Eclipse. I also had to use becker.jar as an external jar file in the Libraries -> Classpath. When I run the program an error…
CosmoCrash
  • 61
  • 1
  • 7
-1
votes
1 answer

Why do I get a NullPointerException for my SmarterSorter program?

I am using BlueJ with Karel the Robot. The program is called SmarterSorter, and here are the instructions: (I need a bit of help with the program over all, not just with the NullPointerException). Background: there are an unknown number of vertical…
1 2
3