terminating a program

I am new to robots and the programming.

I have been playing with programming some.
Everything I try works but it loops continuously.

How do you terminate or stop a program?

We could help if you show us your code and tell us what you are trying to do.
To get help, you must show us your complete sketch. Attach your code using the </> icon on the left side of the posting menu.

.

Everything I try works but it loops continuously.

The name of the loop() function is probably a bit of a clue to what is happening. Once you tell us what you want to do you will get plenty of help.

#define EVER (;;){}
...
...
// and when you're ready to stop
for EVER

Or you could justexit();

rzw0wr:
How do you terminate or stop a program?

Stop with a while(1) forever true loop, after the endstop condition has become true:

if (endstop==true) while(1); // do nothing forever

Or if you really only want the code to run once then just put it in setup()

I found out that I need to learn how to program a sketch first.
Not as easy as I first thought.

What language is best to learn?
C/C++?

Any ideas what programmer software to down load to learn?

The tutorial I am trying to follow is using Eclipse.
Will this software be ok?

Any suggestion on where to start will be helpful.

Thank you,
Dale

Start simple and use the Arduino IDE.
It has a ton of examples built-in