board at null is not available

Hi,
I am trying to connect an accelerometer(GY-521) to an arduino uno, but whenever i click on serial monitor in arduino ide 1.8.9, i get an error message that BOARD AT NULL IS NOT AVAILABLE. The code that i used is taken from internet which is as below:

#include<Wire.h>
const int MPU=0x68;
int16_t AcX,AcY,AcZ,Tmp,GyX,GyY,GyZ;

void setup(){
Wire.begin();
Wire.beginTransmission(MPU);
Wire.write(0x6B);
Wire.write(0);
Wire.endTransmission(true);
Serial.begin(9600);
}
void loop(){
Wire.beginTransmission(MPU);
Wire.write(0x3B);
Wire.endTransmission(false);
Wire.requestFrom(MPU,12,true);
AcX=Wire.read()<<8|Wire.read();
AcY=Wire.read()<<8|Wire.read();
AcZ=Wire.read()<<8|Wire.read();
GyX=Wire.read()<<8|Wire.read();
GyY=Wire.read()<<8|Wire.read();
GyZ=Wire.read()<<8|Wire.read();

Serial.print("Accelerometer: ");
Serial.print("X = “); Serial.print(AcX);
Serial.print(” | Y = “); Serial.print(AcY);
Serial.print(” | Z = "); Serial.println(AcZ);

Serial.print("Gyroscope: ");
Serial.print("X = “); Serial.print(GyX);
Serial.print(” | Y = “); Serial.print(GyY);
Serial.print(” | Z = “); Serial.println(GyZ);
Serial.println(” ");
delay(333);
}

I connected the pins as people explained on internet.
I connected:
VCC to 5V
GND to GND
SCL to A5
SDA to A4
At some sites the instructor also connected INT to 2. But i decided not to do it.

I am new to arduino. So i need help.
Thanks in advance.

(deleted)

Thanks a lot for highlighting my mistake. I was using the wrong serial port. Now the code is running fine.
Regards.