Show all threads Hide all threads Show all messages Hide all messages |
WA#11 | 3a[3.141592..]Jlu | 1530. Ones and Zeroes | 25 Oct 2011 22:26 | 2 |
WA#11 3a[3.141592..]Jlu 18 Jun 2009 03:18 I've got wa#11. But all test in forum my prog give right answers. Please give me more testcase. try this: 8 01100110 01100110 01100110 10000000 |
Which operation is A + B?.. | Enots: Revolution | 1530. Ones and Zeroes | 14 Jul 2008 01:52 | 4 |
Is it: 1) A OR B (element-wise OR) 2) A + B (where A, B are numbers) ?.. (A + B) mod (2^n) ? i.e. string with length n? A+B as numbers, and defined only for non-overflowing addition of same-length sequences Edited by author 14.07.2008 01:52 |
A hint ? | Yosif Yosifov | 1530. Ones and Zeroes | 14 Jul 2008 01:47 | 9 |
A hint ? Yosif Yosifov 20 Feb 2007 01:33 Can someone give me a little hint, please ? make 2 sequences (s1 and s2) such that s1[i]+s2[i]<>2 My solution is based on a greedy approach. I think that an algorithm has many special cases. Main rool:to correct firstly s2[i] from 1 to 0 in pair s1[i]=1 and s2[i]=1 diminishing B but have pair 0, 0 in older position correcting it to 0, 1 for final increasing lexiographicly of B Who can find all cases he solve the problem After getting AC i have counted 6 cases next tests correspong each of cases 4 1011 0011 1011 0100 4 1010 0111 1011 0000 4 1011 0110 1100 0000 4 1111 0101 0000 0000 4 1010 0101 1011 0000 4 1011 0100 1100 0000 Edited by author 21.02.2007 13:58 My program successfully passed all of your test cases, but I still WA3... What can it be??? You are need in additional tests Best if you will create them yourself I have only 3 cases 1) attempt to build a >b 2) attempt to build a+1 0 3) build 0 0 |
help WA 17 | Giorgi Saghinadze (Tbilisi SU) | 1530. Ones and Zeroes | 14 Jul 2008 01:43 | 3 |
help WA 17 Giorgi Saghinadze (Tbilisi SU) 30 Aug 2007 16:41 I think my algo is correct but I still have WA 17. I saw that some people had TLE 17, can anybody tell my what kind of test is it? got AC :) I had very stupid mistake Those TLEs are probably attempts to find test internals because the problem is linear. |
what mean "lexicographically first compatible pair" ? | dibrov.bor[SumySU] | 1530. Ones and Zeroes | 14 Jul 2008 01:40 | 3 |
I try to output zeros in this case, but seems like I'm wrong please show me some example for example for this case 2 11 11 Edited by author 11.12.2007 21:50 This test is correct, and the answer should be 00 00 |
What is the test #3? I Always WA in this test (-) | Dart MirzMan C++ Edition (Mirzoyan Alexey, Rybinsk SAAT) | 1530. Ones and Zeroes | 30 Apr 2007 18:23 | 5 |
I'm too stupid!!! Don't read this!!! It's seems that task is not hard but I still can't solve it I can't find mistakes I have WA3 Really, try this test 5 00110 00110 00110 01000 This one make my solution right. |
what's wrong in my prog? | m2m | 1530. Ones and Zeroes | 23 Feb 2007 05:04 | 1 |
int main() { // freopen("input.txt", "r", stdin); scanf("%d", &n); scanf("%s%s", a, b); FOR(i, n) a[i]-='0',b[i]-='0'; REPD(i, n-1, 0) if(a[i]+b[i]==0 && b[i]==0){ b[i]++; REP(j, i+1, n-1)b[j]=0; out(); return 0; } REPD(i, n-1, 0)if(a[i]==0){ a[i]=1; REP(j, i+1, n-1)a[j]=0; ZERO(b); out(); return 0; } ZERO(a);ZERO(b); out(); return 0; } |
A+B operation | Paul Diac | 1530. Ones and Zeroes | 21 Feb 2007 12:51 | 2 |
If A = "010" and B = "010", then A + B = "100" ? Yes? it is correct. (2+2=4) |
Unclear problem definition(+) | diver[rus] | 1530. Ones and Zeroes | 19 Feb 2007 14:12 | 4 |
I think it's not clear enough that all sequences (especially result pair (a, b)) must have length n. Can you give me a test I have WA3 May be I don't understand problem) Test 3 have uncompatible pair (p, q) try this tests: 2 01 01 answer 01 10 3 101 011 answer: 110 000 Edited by author 19.02.2007 03:47 Thank you! I forgot about this case
|
Is it correct ? | BKHN | 1530. Ones and Zeroes | 18 Feb 2007 17:07 | 2 |
The first compatible pair when there is no pair greater than (p,q) is ('000000....00' , '0000000...00' ) , isn't it ? I got WA test 22nd , please help me a bit . |
Correct Answer | Witek Szymaniak | 1530. Ones and Zeroes | 18 Feb 2007 16:16 | 1 |
Isn't correct answer for test INPUT: 2 01 10 OUTPUT: 1 0 Instead of 10 00 Cause 1 < 10 and I don't see that anywhere is written that the pair of sequences (a,b) should be the same length as (p,q) |
Are there sequences p and q compatible? | Stepanko%POLYTEH% | 1530. Ones and Zeroes | 18 Feb 2007 15:13 | 3 |
Are there sequences p and q compatible? UPD: Sorry, first time I misunderstood the question Edited by author 18.02.2007 15:34 Re: Yes (-) Dart MirzMan C++ Edition (Mirzoyan Alexey, Rybinsk SAAT) 18 Feb 2007 15:13 I think, in test #3 they are not |