Record Case Detail

Notes

This function is in beta test. Please help improve it in the issues here.

Stderr

=================================================================
==23941==ERROR: AddressSanitizer: stack-buffer-overflow on address 0x7ffc0e17a540 at pc 0x55c1d3264bb9 bp 0x7ffc0e179cc0 sp 0x7ffc0e179cb0
WRITE of size 4 at 0x7ffc0e17a540 thread T0
    #0 0x55c1d3264bb8 in main (/out/package/sam_mem+0x5bb8)
    #1 0x7ff4bc25db96 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x21b96)
    #2 0x55c1d3265169 in _start (/out/package/sam_mem+0x6169)

Address 0x7ffc0e17a540 is located in stack of thread T0 at offset 2000 in frame
    #0 0x55c1d326122f in main (/out/package/sam_mem+0x222f)

  This frame has 23 object(s):
    [32, 33) '<unknown>'
    [96, 100) 'opsize'
    [160, 164) 'instsize'
    [224, 228) 'temp'
    [288, 292) '<unknown>'
    [352, 356) '<unknown>'
    [416, 420) 'temp2'
    [480, 484) 'temp1'
    [544, 576) '__tmp'
    [608, 640) '__tmp'
    [672, 704) '__tmp'
    [736, 768) '__tmp'
    [800, 832) '__tmp'
    [864, 896) '__tmp'
    [928, 960) '__tmp'
    [992, 1024) '__tmp'
    [1056, 113

Hints

Your answer may be identical to the JOJ answer in the first several lines.

However, the main problem you meet now is Runtime Error. And the exit code of your program is 1, which should be 0.

Please double check your code to solve this problem and try again.

Your Answer


        

JOJ Answer

NOR
93180588 53515141 42568661 14129092 9298915 96248587 44944310 53880501 98355984 84222140 93992653 63629501 66042518 88488684 51125851 37920855 65062089 20620620 43519219 46953676 84108375 76879852 71503070 51547448 62415788 17439474 5187854 87061720 66525047 93326794 39140258 6461312 78672915 -90569980 
NOOP PUSHI 6 LOAD ADD PUSHI 713544042 POP IFZ 15 NOOP NOR PUSHI 0 IFZ 5 ADD STORE NOOP POP LOAD PUSHI 10 STORE PUSHI 4 LOAD POP POP POP NOOP NOOP ADD PUSHI 3 LOAD PUSHI 554459755 NOOP PUSHI 1580286484 PUSHI 5 STORE IFZ 16 PUSHI 1819880699 PUSHI 6 STORE POP PUSHI 8 STORE PUSHI 8 LOAD NOR PUSHI 2 LOAD PUSHI 13 LOAD PUSHI 2119072701 IFZ 0 POP PUSHI 1 STORE PUSHI 623345146 NOOP POP PUSHI 0 IFZ 25 HALT HALT LOAD NOR ADD LOAD PUSHI 1212838840 PUSHI 883731696 LOAD NOOP NOR POP PUSHI 1164914762 PUSHI 1525324784 ADD ADD STORE NOR POP ADD IFZ 30 NOR NOR ADD LOAD PUSHI 1168530389 NOOP PUSHI 3 LOAD NOOP POP PUSHI 0 IFZ 18 NOOP STORE NOR POP NOOP IFZ 6 POP NOR STORE NOOP STORE IFZ 1 ADD HALT PUSHI 1765334898 LOAD POP N