All submissions

Solving Approach

How do you plan to solve it?

 
 

Hardware connection:

  • Connect the anode (long leg) of the LED to pin 4 through a current-limiting resistor (e.g., 220Ω).
  • Connect the cathode (short leg) to GND on the Arduino.

 

 

Code

/*Paste your code here*/
int LED = 4;

void setup() {
  pinMode(LED, OUTPUT); // Set pin 4 as an output
}

void loop() {
  digitalWrite(LED, HIGH); // Turn the LED on
  delay(500);              // Wait for 500 milliseconds
  digitalWrite(LED, LOW);  // Turn the LED off
  delay(500);              // Wait for 500 milliseconds
}

 

 

 

Output

Video

Add video of the output (know more)

 

 

Photo of Output

Add a photo of your hardware showing the output.

 

 

Submit Your Solution

Note: Once submitted, your solution goes public, helping others learn from your approach!