Check out example codes for "how to print to the serial monitor arduino". It will help you in understanding the concepts better.

Code Example 1

void setup()
{
    Serial.begin( 9600 );
}

void loop()
{
    // This will write to the monitor and end the line
    Serial.println( "test text" );
  
    // This will write to the monitor but will not end the line
    Serial.print( "test text" );
}

Learn ReactJs, React Native from akashmittal.com