void setup() {
Serial.begin(9600); //Start serial communjcation at 9600 baud
Serial.println("input number: ");
}
void loop() {
//Check if data is available in the Serial Monitor
if (Serial.available() > 0) {
//read the input from the serial monitor and convert it to an integer
int angka = Serial.parseInt();
Serial.read(); //Read and discard the newline character
Serial.println(angka); //Display the entered number
}
}