avrdude: ser_open(): can't open device

Arduino: 1.8.9 (Windows 10), Board: "Arduino/Genuino Uno"

Sketch uses 1868 bytes (5%) of program storage space. Maximum is 32256 bytes.
Global variables use 188 bytes (9%) of dynamic memory, leaving 1860 bytes for local variables. Maximum is 2048 bytes.
avrdude: ser_open(): can't open device "\.\COM4": The system cannot find the file specified.

Problem uploading to board. See Arduino Help Center for suggestions.

This report would have more information with
"Show verbose output during compilation"
option enabled in File -> Preferences.

Arduino: 1.8.9 (Windows 10), Board: "Arduino/Genuino Uno"

You have the wrong board selected, you need Tools > Board > Arduino Nano

There are two different bootloaders for the Nano, either Tools > Processor > ATmega328P or Tools > Processor > ATmega328P (Old Bootloader), you will have to try both to see which is correct for your board.

This is the second time I've had to split your hijack post off a thread @ak8962726177. This is your final warning. If you do it again, I'm going to give you an account suspension.

how to tare the analog reading by use push switch .

Reads an analog input on pin 0, converts it to voltage, and prints the result to the serial monitor.
Attach the center pin of a potentiometer to pin A0, and the outside pins to +5V and ground.

This example code is in the public domain.

// the setup routine runs once when you press reset:
void setup() {
// initialize serial communication at 9600 bits per second:

// the loop routine runs over and over again forever:
void loop() {
// read the input on analog pin 0:
int sensorValue = analogRead(A0);
// Convert the analog reading (which goes from 0 - 1023) to a voltage (0 - 5V):
float voltage = sensorValue * (5.0 / 1023.0);
// print out the value you read: