int buttonPin = A0;
int LED = 13;
void setup() {
pinMode(buttonPin, INPUT);
pinMode(LED, OUTPUT);
}
void loop(){
if (digitalRead(buttonPin) == HIGH){
digitalWrite(LED, HIGH);
} else {
// Otherwise, turn the LED off
digitalWrite(LED, LOW);
}
}