The compilation was successful
The multiplication should have been performed at compile time without any code being generated.
However, your solution generated the following code:
Java HotSpot(TM) 64-Bit Server VM warning: Can't detect initial thread stack location - find_vma failed
mov ax,5
mov ax,6
mul ax
[ the expected value was 30, but you calculated the result as 6 ]
I entered some code in my school’s system and I got this error message. I don’t understand the part where it says “The multiplication should have been performed at compile time without any code being generated.”.
Anyone know what I might be doing wrong?
(I can’t reveal the code I entered in it, because I don’t want it showing up in a search engine. Is there a way I can privately show the code I entered in?)
The
Can't detect initial thread stack locationsuggests an incomplete or corrupt Java installation.The stuff about multiplication at compile time doesn’t look like it comes from Java, but instead from some sort of IDE or compilation tool that your school is using. Whatever this “school system” is, you need to ask whoever is responsible for it about these error messages.