Search found 48 matches
- Wed Feb 24, 2016 12:03 pm
- Forum: Volume 106 (10600-10699)
- Topic: 10674 - Tangents
- Replies: 13
- Views: 5236
Re: 10674 - Tangents
Tested all I/O found on udebug... don't know where is the problem. Still getting WA. Please help!! #include<bits/stdc++.h> using namespace std; #define ms(x,val) memset(x,val,sizeof(x)) #define scan(x) scanf("%d",&x) #define print(x) printf("debug= %d\n",x) #define ull unsign...
- Wed Oct 29, 2014 12:56 pm
- Forum: Volume 119 (11900-11999)
- Topic: 11997 - K Smallest Sums
- Replies: 1
- Views: 1033
Re: 11997 - K Smallest Sums
Need some hints about the solution method...No Idea...
- Sun Sep 14, 2014 9:26 pm
- Forum: Volume 127 (12700-12799)
- Topic: 12785 - Emacs Plugin
- Replies: 1
- Views: 955
Re: 12785 - Emacs Plugin
I used KMP algorithm... but getting WA... tried every test cases I can think of... :( #include<bits/stdc++.h> using namespace std; #define ms(x,val) memset(x,val,sizeof(x)) #define ull unsigned long long #define iii long long #define pi acos(-1) #define pb push_back #define PII pair<int,int> #define...
- Thu Sep 11, 2014 6:54 pm
- Forum: Volume 101 (10100-10199)
- Topic: 10148 - Advertisement
- Replies: 1
- Views: 753
Re: 10148 - Advertisement
What is the algorithm for solving this kind of problem? Can this be solved using Binary Indexed Tree?
- Sun Apr 27, 2014 2:03 am
- Forum: Volume 100 (10000-10099)
- Topic: 10032 - Tug of War
- Replies: 91
- Views: 34477
Re: 10032 - Tug of War
Getting TLE please help. here is my code: #include<bits/stdc++.h> using namespace std; #define ms(x,val) memset(x,val,sizeof(x)) #define ull unsigned long long #define iii long long #define pi acos(-1) #define repi(i,a,n) for(int i=a;i<n;i++) #define pb push_back #define PII pair<int,int> #define MP...
- Fri Jan 17, 2014 3:03 pm
- Forum: Volume 121 (12100-12199)
- Topic: 12160 - Unlock the Lock
- Replies: 4
- Views: 1378
Re: 12160 - Unlock the Lock
I am surprised. I did not cleared the vector. But after clearing I din't submit it. So sorry. That is an AC code.brianfry713 wrote:That is AC code
- Fri Jan 10, 2014 7:21 pm
- Forum: Volume 109 (10900-10999)
- Topic: 10924 - Prime Words
- Replies: 44
- Views: 23489
Re: 10924 - Prime Words
I was trying to say that the problem statement is contradictory...
- Fri Jan 10, 2014 9:14 am
- Forum: Volume 121 (12100-12199)
- Topic: 12160 - Unlock the Lock
- Replies: 4
- Views: 1378
- Sun Dec 08, 2013 7:45 pm
- Forum: Volume 7 (700-799)
- Topic: 793 - Network Connections
- Replies: 102
- Views: 33745
Re: 793 - Network Connections
There is no blank line after the last dataset. So be careful about EOF to avoid TLE. 

- Fri Dec 06, 2013 12:49 am
- Forum: Volume 115 (11500-11599)
- Topic: 11504 - Dominos
- Replies: 55
- Views: 22772
Re: 11504 - Dominos
prooblem: Domino ID:11504 Why getting wrong answer?? Please help... #include<iostream> #include<cstdio> #include<vector> #include<queue> #include<map> #include<cstring> using namespace std; int main() { int cases,len,n,count,l,m,temp,temp2,top; vector<int>v[100010]; vector<int> done; bool color[1000...
- Wed Dec 04, 2013 11:28 am
- Forum: Volume 102 (10200-10299)
- Topic: 10281 - Average Speed
- Replies: 39
- Views: 16058
Re: 10281 - Average Speed
Thanks brianfry... 

- Sun Nov 24, 2013 3:33 pm
- Forum: Volume 109 (10900-10999)
- Topic: 10924 - Prime Words
- Replies: 44
- Views: 23489
Re: 10924 - Prime Words
As the problem statement is a prime number has only two divisors (1 and itself) , 1 should not be added to the list of prime numbers....
- Sat Nov 02, 2013 9:32 pm
- Forum: Volume 100 (10000-10099)
- Topic: 10034 - Freckles
- Replies: 101
- Views: 35088
Re: 10034 - Freckles
Nice problem... Got ac . I solved this using Prim's algorithm. BUT my runtime is very bad. Any suggestion about optimizing my code will be appreciated. Thanks.
- Sat Nov 02, 2013 12:03 am
- Forum: Volume 5 (500-599)
- Topic: 544 - Heavy Cargo
- Replies: 32
- Views: 15299
Re: 544 - heavy cargo
thanks... brainfry... got AC...
- Wed Oct 30, 2013 4:42 pm
- Forum: Volume 102 (10200-10299)
- Topic: 10220 - I Love Big Numbers !
- Replies: 18
- Views: 8066
Re: 10220 - I Love Big Numbers !
It is so annoying...why this is like it????
int this problem: 10220 (I love big integers) it gives WA when i was using...
but it is AC when i changed it to scan until EOF. Be careful about that...
int this problem: 10220 (I love big integers) it gives WA when i was using...
Code: Select all
while(scanf("%d",&n)==1)
{
,,,
}