error compiling for board

I cannot upload code to board here is the code I used:
#include <Servo.h> //controlling servo with potentiometer
Servo myservo;

void setup(){
myservo.attach(7);
pinMode(A0,INPUT); //set modes
}

void loop(){
int pot = analogRead(A0);
int mapped = map(pot, 0, 1023, 0, 180); //use map command to control servo
myservo.write(mapped);
}

-------end of code-----------------------------------------------------------------------------------------------
here is the error message I get:
Arduino: 1.8.2 (Windows Store 1.8.2.0) (Windows 10), Board: "Arduino/Genuino Uno"

Exception 0xc0000090 0x0 0x0 0x112842
PC=0x112842

syscall.Syscall12(0x7407e320, 0xa, 0x12732b40, 0x12a9e000, 0x0, 0x0, 0x1, 0x400, 0x12772d00, 0x0, ...)
/home/jenkins/go/src/runtime/syscall_windows.go:196 +0x4a
syscall.CreateProcess(0x12732b40, 0x12a9e000, 0x0, 0x0, 0x1, 0x400, 0x12772d00, 0x0, 0x12741330, 0x127412dc, ...)
/home/jenkins/go/src/syscall/zsyscall_windows.go:583 +0x112
syscall.StartProcess(0x12aca0e0, 0x70, 0x12758000, 0x1b, 0x1c, 0x127413e8, 0x0, 0x0, 0x0, 0x0)
/home/jenkins/go/src/syscall/exec_windows.go:326 +0x722
os.startProcess(0x12aca0e0, 0x70, 0x12758000, 0x1b, 0x1c, 0x1274151c, 0x12ac4820, 0x0, 0x0)
/home/jenkins/go/src/os/exec_posix.go:45 +0x293
os.StartProcess(0x12aca0e0, 0x70, 0x12758000, 0x1b, 0x1c, 0x1274151c, 0x0, 0x0, 0x0)
/home/jenkins/go/src/os/doc.go:28 +0x53
os/exec.(*Cmd).Start(0x127660b0, 0x0, 0x0)
/home/jenkins/go/src/os/exec/exec.go:358 +0x6fa
os/exec.(*Cmd).Run(0x127660b0, 0x0, 0x0)
/home/jenkins/go/src/os/exec/exec.go:276 +0x2b
arduino.cc/builder/builder_utils.ExecRecipeCollectStdErr(0x1278c1a0, 0x56c313, 0x15, 0x1, 0x5f4880, 0x614ef0, 0x0, 0x0, 0x0, 0x0)
/home/jenkins/workspace/arduino-builder-all-cross/src/arduino.cc/builder/builder_utils/utils.go:413 +0x118
arduino.cc/builder.(*GCCPreprocRunnerForDiscoveringIncludes).Run(0x1278c180, 0x1278e000, 0x0, 0x0)
/home/jenkins/workspace/arduino-builder-all-cross/src/arduino.cc/builder/gcc_preproc_runner.go:93 +0x23c
arduino.cc/builder.runCommand(0x1278e000, 0x5f39b0, 0x1278c180, 0x0, 0x0)
/home/jenkins/workspace/arduino-builder-all-cross/src/arduino.cc/builder/container_find_includes.go:183 +0x57
arduino.cc/builder.findIncludesUntilDone(0x1278e000, 0x12ad5da0, 0x538ca0, 0x12aeaa50, 0x12ad5de0, 0x18, 0x0, 0x0)
/home/jenkins/workspace/arduino-builder-all-cross/src/arduino.cc/builder/container_find_includes.go:331 +0x1810
arduino.cc/builder.(*ContainerFindIncludes).Run(0x614ef0, 0x1278e000, 0x0, 0x0)
/home/jenkins/workspace/arduino-builder-all-cross/src/arduino.cc/builder/container_find_includes.go:149 +0xdfd
arduino.cc/builder.runCommands(0x1278e000, 0x12741cc8, 0x22, 0x22, 0x1, 0x0, 0x0)
/home/jenkins/workspace/arduino-builder-all-cross/src/arduino.cc/builder/builder.go:191 +0xe2
arduino.cc/builder.(*Builder).Run(0x12741dec, 0x1278e000, 0x0, 0x0)
/home/jenkins/workspace/arduino-builder-all-cross/src/arduino.cc/builder/builder.go:124 +0x89f
arduino.cc/builder.RunBuilder(0x1278e000, 0x0, 0x0)
/home/jenkins/workspace/arduino-builder-all-cross/src/arduino.cc/builder/builder.go:222 +0x35
main.main()
/home/jenkins/workspace/arduino-builder-all-cross/src/arduino.cc/arduino-builder/main.go:338 +0x1360
eax 0x0
ebx 0x33156008
ecx 0x0
edx 0x330f0000
edi 0x4b78
esi 0x33156000
ebp 0xdf6d4
esp 0xdf6ac
eip 0x112842
eflags 0x10216
cs 0x23
fs 0x53
gs 0x2b
C:\Program Files\WindowsApps\ArduinoLLC.ArduinoIDE_1.8.2.0_x64__mdqgnx93n4wtt\arduino-builder returned 2
Error compiling for board Arduino/Genuino Uno.


please help and thank you in advance.

Hi,
Have you tried an earlier version of the IDE, 1.8.2 is pretty recent, it may have some bugs.

Tom.. :slight_smile:

thanks all my other codes including this one are working in 1.0.6

You could try the regular version of Arduino IDE 1.8.2, not the Windows Store version. 1.8.2 is very stable. The only notable bug that has surfaced since the release is a problem with the Linux install script so not relevant to you. Not as many people use the Windows Store version so there may be a problem specific to that version.