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

Common Board

How to solve problems in 0.001sec?
Posted by hatred 14 Aug 2011 15:35
This is my A+B problem code. It accepted in 0.015 sec. How to make it faster to run in 0.001?

#include <cstdio>
int main() {
    register int a,b;
    scanf("%d %d",&a,&b);
    __asm {
        mov eax,a
        add eax,b
        mov a,eax
    }
    printf("%d",a);
    return 0;
}

And these 3725342 & 3725343 submits are the same, but has different run time.
Re: How to solve problems in 0.001sec?
Posted by hatred 21 Aug 2011 02:01
up
Re: How to solve problems in 0.001sec?
Posted by daftcoder [Yaroslavl SU] 22 Aug 2011 12:20
It was done with an old compiler, now it's impossible.