const unsigned int digitalInPin = 5; //GPIO5 >>> D3
bool sensorValue = 0;

void setup() 
{ 
  Serial.begin(115200);
  pinMode(digitalInPin, INPUT);
} 
void loop()
{ 
  sensorValue = digitalRead(digitalInPin);
  Serial.print("Sensor = " );
  Serial.print(sensorValue);
  if(sensorValue){
    Serial.println(" , Water is detected!");
  }else{
    Serial.println(" , No water was detected!");
  }
  delay(1000); 
}
