Bug using global anonymous struct in GNU C++11

Revision en1, by pimenta, 2017-03-02 02:54:50


I've sent submission 25136808 using a global anonymous struct with some big arrays and methods inside. The submission got RTE case 7.

Next, I send submission 25137642 only removing the struct from around the arrays and the methods, and I got AC.

Then I thought "maybe the global arrays are not being initialized to zero when they are inside the struct". So I called memset(&st,0,sizeof st); and I got RTE case 7 again: 25137670.

What's the deal with structs in Codeforces? All these 3 codes work fine I'm my notebook in test case 7.


  Rev. Lang. By When Δ Comment
en5 English pimenta 2017-03-02 04:00:41 103
en4 English pimenta 2017-03-02 03:43:47 177
en3 English pimenta 2017-03-02 02:59:22 7 Tiny change: 'I've just tested the sa' -> 'I've just submitted the sa'
en2 English pimenta 2017-03-02 02:58:40 129
en1 English pimenta 2017-03-02 02:54:50 635 Initial revision (published)