Solved! Uno stop the loop, blinks three times on pin 13, then restarts loop.

I have just bought the uno and is trying to understand the programming part.

But no matter what I try running, it "breaks" the loop to blink pin 13 three times.

I have no trouble uploading, I only have trouble running programs. Of course I've tried the K.I.T.T. lights, it will break sequense, apparently at random, but restart at pin 4 (which is the first pin).

Same sort of thing happens with 'blink'

I'm running of the USB-cable.

Any help/hints or pointers will be appreciated.

Sounds like your board is resetting. Usually a voltage source or current draw problem.

Found that the problem was computer/PSU related.

The external PSU for my USB hub, had fallen out of the socket. Therefore running on USB power from the PC.

It could draw power(through USB) while the PC was shut down, and everything worked fine. But when I rebooted my PC, problem was back. When I figured out that the hub was unplugged and plugged it in, the problem was gone.

Thank you for your replies.