Im trying to get my serial data to be outputted with 2 decimals so 00, 01, 02, 03, 04, ect...
Is there something I can add to this code:
void setup() {
Serial.begin(9600);
}
void loop() {
for(int i=0; i<=100;i++) {
for(int j=16; j<=199;j++) {
Serial.print(i, DEC);
Serial.println(j, DEC);
delay(50);
}
}
}
Without having code like this :
void setup() {
Serial.begin(9600);
}
void loop() {
for(int i=0; i<=100;i++) {
for(int j=0; j<=100;j++) {
if(i<10){Serial.print("0");}
Serial.print(i, DEC);
if(j<10){Serial.print("0");}
Serial.println(j, DEC);
delay(50);
}
}
}