the first code any arduino beginner should see

void setup() {//this function runs forever
  pinMode(LED_BUILTIN, OUTPUT);//this configure the pin for sensor input
}
//white space increased the speed of the code, the more the better

void loop() { //this function runs only once
  digitalWrite(LED_BUILTIN, HIGH);//this sets the pin in a sensor input low impedance mode
  delay(1000);//this is a delay to wait(in minutes)
  digitalWrite(LED_BUILTIN, LOW);//this sets the pin as an output to run high current things like motors
  delay(1000 );//same as above, but because a space is inside the parentheses the value is multiplied by 2.4
}//this tells the arduino to repeat the code 3 more times

To me the he joke is not very funny.
You want to show new people some code full of incorrect comments ?
Not a single comment is correct, and there's a lot of them.

MAS3:
To me the he joke is not very funny.

+1

Always keep in mind that the Forum will be read by people without experience - after all they are our principal customers.

...R

{ and } prevents the code from spilling onto the floor.

Should this be part of the "Priceless in a really sad way" topic?

sorry everyone this was just a joke but yeah you all are right

Don't worry, sometimes ideas inside your head just don't work so well in real life. Been there and done that more than one man should...

Cheers,
Kari

FIRE!

GaryP:
Don't worry, sometimes ideas inside your head just don't work so well in real life. Been there and done that more than one man should...

Cheers,
Kari

Thanks for the encouragement!

I have thought about the blink sketch, which is probably the first code beginners normally see. It would be better if the official example blink sketch were replaced with a simple as possible and properly commented blink without delay in the Arduino IDE distribution. My first exposure to programming was back when goto was in style, and although available in many programming languages it is just not used any more, and new users are not introduced to it. The same treatment could be done with delay.

I think of the number of times I've corrected mistakes stemming from the BWD example, using signed variables to work with time and that's just over one goofball mistake.

Please don't make it worse! Some people get an idea and cling to it like a loyalty oath, all evidence to the contrary becomes some kind of personal fight.

If there were a simple threading model built in, they could be introduced to "sleep()" and go off to do something else?

-jim lee

Introduce them to workToLearn() and see how many don't sleep() instead.