ENG  RUSTimus Online Judge
Online Judge
Problems
Authors
Online contests
About Online Judge
Frequently asked questions
Site news
Webboard
Links
Problem set
Submit solution
Judge status
Guide
Register
Update your info
Authors ranklist
Current contest
Scheduled contests
Past contests
Rules
back to board

Discussion of Problem 1015. Test the Difference!

This is very very strange...
Posted by Active User 22 Oct 2008 20:14
this C++ code work correctly on my machine and on Timus's:
{
a[b][c[b]++] = i;
b++;
}

but this code work incorrectly on Timus:
{
a[b][c[b++]++] = i;
}

I have spent half-day to find this bug.
The behavior of this code is unpredictable. Don't do that.
Posted by Vladimir Yakovlev (USU) 22 Oct 2008 20:48
Re: This is very very strange...
Posted by Yin Zhu 15 Jul 2009 22:07
I think it is not a good habbit to write a program like that.

Edited by author 15.07.2009 22:08