coalscam WA!!!

hey after implementing the editorials i m still getting WA…
plzzz…help me up http://www.codechef.com/viewsolution/2671811

Do not print the road’s value+ U might get TLE as the question reckons FAST_INPUT usage.

#define llu long long int
llu scan()
{
    llu noRead=0;
    char p= getchar_unlocked();
    for(;p<33;)
    {
     p=getchar_unlocked();
    };
    while(p>32)
    {
     noRead = (noRead << 3) + (noRead << 1) + (p - '0');
     p=getchar_unlocked();
    }
    return noRead;
};

Also use long long int as the answer might overflow the trivial int type.

soorry bt mistake i did post the wrong link
heres my new one http://www.codechef.com/viewsolution/2672337
after removing the road value

the code finalyy worked after changing int to long long int .
thnx for ur help.:slight_smile:

//