ENG
RUS
Timus 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
1098
. Questions
Wow, O(n^2) int Java got AC
Posted by
Izaron
20 Aug 2016 13:02
This code in Java:
int v = 0;
int n = 1998;
while (buffer.length() > 1) {
v += n;
v %= buffer.length();
buffer.deleteCharAt(v);
}
Got AC in 0.109 time
© 2000–2024
Timus Online Judge Team
. All rights reserved.