Record Case Detail

Notes

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

Stderr

/in/ex1.cpp:16:9: runtime error: index 1000 out of bounds for type 'int [1000]'
SUMMARY: UndefinedBehaviorSanitizer: undefined-behavior /in/ex1.cpp:16:9 in 
=================================================================
==51265==ERROR: AddressSanitizer: stack-buffer-overflow on address 0x7ffdaabb86a0 at pc 0x00000051a4ed bp 0x7ffdaabb76d0 sp 0x7ffdaabb76c8
WRITE of size 4 at 0x7ffdaabb86a0 thread T0
    #0 0x51a4ec  (/out/package/ex1+0x51a4ec)
    #1 0x51a029  (/out/package/ex1+0x51a029)
    #2 0x7f039cc25b96  (/lib/x86_64-linux-gnu/libc.so.6+0x21b96)
    #3 0x41d759  (/out/package/ex1+0x41d759)

Address 0x7ffdaabb86a0 is located in stack of thread T0 at offset 4032 in frame
    #0 0x51a1bf  (/out/package/ex1+0x51a1bf)

  This frame has 1 object(s):
    [32, 4032) 'a' <== Memory access at offset 4032 overflows this variable
HINT: this may be a false positive if your program uses some custom stack unwind mechanism or swapcontext
      (longjmp and C++ exceptions *are* supported)
SUMMARY: AddressSanitizer: s

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

jr luther martin king in published jr king luther martin brotherhood and peace of cause the for yours beauty scintillating their all with nation great our over shine will brotherhood and love of stars radiant the tomorrow distant too not some in and communities drenched fear our from lifted be will misunderstanding of fog deep the and away pass soon will prejudice racial of clouds dark the that hope all us let brother christian a and clergyman fellow a as but leader civil-rights a or integrationist an as not you of each meet to me for possible it make soon will circumstances that hope also i faith the in strong you finds letter this hope i independence of declaration the and constitution the of formulation their in fathers founding the by deep dug were which democracy of wells great those to back nation our bringing thereby heritage christian judaeo our in values sacred most the for and dream american the in best is what for up standing reality in were they counters lunch at down sat god of children disinheri