fork download
  1. int led_pin = 13;
  2.  
  3. void setup() {
  4. // put your setup code here, to run once:
  5. pinMode(led_pin, OUTPUT);
  6. }
  7.  
  8. void loop() {
  9. // put your main code here, to run repeatedly:
  10. digitalWrite(led_pin, HIGH);
  11. delay(1000);
  12. digitalWrite(led_pin, LOW);
  13. delay(1000);
  14. }
Compilation error #stdin compilation error #stdout 0s 0KB
stdin
Standard input is empty
compilation info
prog.cpp: In function 'void setup()':
prog.cpp:5:20: error: 'OUTPUT' was not declared in this scope
   pinMode(led_pin, OUTPUT);
                    ^
prog.cpp:5:26: error: 'pinMode' was not declared in this scope
   pinMode(led_pin, OUTPUT);
                          ^
prog.cpp: In function 'void loop()':
prog.cpp:10:25: error: 'HIGH' was not declared in this scope
   digitalWrite(led_pin, HIGH);
                         ^
prog.cpp:10:29: error: 'digitalWrite' was not declared in this scope
   digitalWrite(led_pin, HIGH);
                             ^
prog.cpp:11:13: error: 'delay' was not declared in this scope
   delay(1000);
             ^
prog.cpp:12:25: error: 'LOW' was not declared in this scope
   digitalWrite(led_pin, LOW);
                         ^
stdout
Standard output is empty