नीचे दिए गए कोड का उद्देश्य क्या है यदि इसे Arduino Uno पर निष्पादित किया जाता है?
What is the objective of the code given below if it is executed on the Arduino Uno ?
#include<EEPROM.h>
int pin=13;
void setup() {
pinMode(pin,OUTPUT);
Serial.begin(9600);
}
void loop() {
for(int i=0; i<EEPROM.length(); i++) {
EEPROM.write(i, 1);
}
digitalWrite(pin,HIGH);
exit(0);
}
A)
B)
C)
D)
Explanation:
The code writes the value 1 to every location in the EEPROM of the Arduino Uno, filling the entire EEPROM with 1's. It also turns on the LED connected to pin 13 and then exits the program.
Correct Answer:
(B) Fill EEPROM with 1's.