![:D](./images/smilies/icon_biggrin.gif)
11946 - Code Number
Moderator: Board moderators
Re: 11946 - Code Number
AC ![:D](./images/smilies/icon_biggrin.gif)
![:D](./images/smilies/icon_biggrin.gif)
Last edited by TLEorWA on Tue Apr 01, 2014 11:52 am, edited 1 time in total.
-
- Guru
- Posts: 5947
- Joined: Thu Sep 01, 2011 9:09 am
- Location: San Jose, CA, USA
Re: 11946 - Code Number
You must print a blank line between each test case. Don't print an extra blank line at the end.
Check input and AC output for thousands of problems on uDebug!
Re: 11946 - Code Number
Also, if you're going to be sharing code using Pastebin (or other similar sites) then note that code can be syntax highlighted. Makes things easier to read for people reviewing your code.TLEorWA wrote:WA,help?
-
- Experienced poster
- Posts: 148
- Joined: Sun Jul 13, 2014 4:32 am
- Location: Rangpur, Bangladesh
Re: 11946 - Code Number
Last edited by Shahidul.CSE on Tue Jul 22, 2014 6:52 pm, edited 3 times in total.
Md. Shahidul Islam
Dept. of CSE at Begum Rokeya University, Rangpur, Bangladesh
UVa id: http://uhunt.felix-halim.net/id/438420
My facebook account,
Email me: shahidul.cse.brur@gmail.com
Dept. of CSE at Begum Rokeya University, Rangpur, Bangladesh
UVa id: http://uhunt.felix-halim.net/id/438420
My facebook account,
Email me: shahidul.cse.brur@gmail.com
Re: 11946 - Code Number
Don't read from file
A person who sees the good in things has good thoughts. And he who has good thoughts receives pleasure from life... Bediuzzaman
-
- Experienced poster
- Posts: 148
- Joined: Sun Jul 13, 2014 4:32 am
- Location: Rangpur, Bangladesh
Re: 11946 - Code Number
I did that only for checking by myself.
Why WA?
Why WA?
Md. Shahidul Islam
Dept. of CSE at Begum Rokeya University, Rangpur, Bangladesh
UVa id: http://uhunt.felix-halim.net/id/438420
My facebook account,
Email me: shahidul.cse.brur@gmail.com
Dept. of CSE at Begum Rokeya University, Rangpur, Bangladesh
UVa id: http://uhunt.felix-halim.net/id/438420
My facebook account,
Email me: shahidul.cse.brur@gmail.com
Re: 11946 - Code Number
Remove this line and you will get accepted.
Copy/paste from post above. ![:D](./images/smilies/icon_biggrin.gif)
Code: Select all
freopen("11946.txt", "r", stdin);
![:D](./images/smilies/icon_biggrin.gif)
A person who sees the good in things has good thoughts. And he who has good thoughts receives pleasure from life... Bediuzzaman
-
- Experienced poster
- Posts: 148
- Joined: Sun Jul 13, 2014 4:32 am
- Location: Rangpur, Bangladesh
Re: 11946 - Code Number
Thank you, got accepted !
it was my mistake. When I submitted, I didn't remove that line.
![:D](./images/smilies/icon_biggrin.gif)
it was my mistake. When I submitted, I didn't remove that line.
Md. Shahidul Islam
Dept. of CSE at Begum Rokeya University, Rangpur, Bangladesh
UVa id: http://uhunt.felix-halim.net/id/438420
My facebook account,
Email me: shahidul.cse.brur@gmail.com
Dept. of CSE at Begum Rokeya University, Rangpur, Bangladesh
UVa id: http://uhunt.felix-halim.net/id/438420
My facebook account,
Email me: shahidul.cse.brur@gmail.com
Re: 11946 - Code Number
Code: Select all
Removed after getting accepted! Unlimited thanks to brianfry713.
Last edited by bgcsaif on Fri Oct 03, 2014 11:28 am, edited 1 time in total.
-
- Guru
- Posts: 5947
- Joined: Thu Sep 01, 2011 9:09 am
- Location: San Jose, CA, USA
Re: 11946 - Code Number
Try running your code on the sample input.
Check input and AC output for thousands of problems on uDebug!
Re: 11946 - Code Number
I tried all sample inputs. It's ok. And i seperated each test cases with a blank line. But i got WA. Please, have a close look. I might be wrong somewhere. Thank you.
-
- Guru
- Posts: 5947
- Joined: Thu Sep 01, 2011 9:09 am
- Location: San Jose, CA, USA
Re: 11946 - Code Number
http://ideone.com/qlkB8C
For the sample input, your output is:The correct output is:
For the sample input, your output is:
Code: Select all
HELLO MY LOVE, I M HAPPY BECAUSE SOON I WILL BE TO YOUR SIDE. THIS
Code: Select all
HELLO MY LOVE, I M HAPPY BECAUSE SOON I WILL BE TO YOUR SIDE. THIS
TIME WITHOUT YOU HAS BEEN ETERNAL. I INVITE YOU TO THE ZOO ONE TO
SEE THE ZEBRAS AND GORILAS.
Check input and AC output for thousands of problems on uDebug!
Re: 11946 - Code Number
Sir, I don't know what's wrong. But you must believe I am getting complete output on my IDE(GNU-GCC WINGMINGW-CODEBLOCKS). Can you help me with any hints or information please? Thank you . . . .
-
- Guru
- Posts: 5947
- Joined: Thu Sep 01, 2011 9:09 am
- Location: San Jose, CA, USA
Re: 11946 - Code Number
The first line of input gives the number of test cases, not the number of lines.
For input:The output should be:
You changed the sample input to be all on one line, which it is not, it is on 3 lines.
For input:
Code: Select all
2
H3LL0 MY L0V3, 1 M H499Y 83C4U53 500N 1 W1LL 83 70 Y0UR 51D3. 7H15
71M3 W17H0U7 Y0U H45 833N 373RN4L. 1 1NV173 Y0U 70 7H3 200 0N3 70
533 7H3 238R45 4ND 60R1L45.
H3LL0 MY L0V3, 1 M H499Y 83C4U53 500N 1 W1LL 83 70 Y0UR 51D3. 7H15
71M3 W17H0U7 Y0U H45 833N 373RN4L. 1 1NV173 Y0U 70 7H3 200 0N3 70
533 7H3 238R45 4ND 60R1L45.
Code: Select all
HELLO MY LOVE, I M HAPPY BECAUSE SOON I WILL BE TO YOUR SIDE. THIS
TIME WITHOUT YOU HAS BEEN ETERNAL. I INVITE YOU TO THE ZOO ONE TO
SEE THE ZEBRAS AND GORILAS.
HELLO MY LOVE, I M HAPPY BECAUSE SOON I WILL BE TO YOUR SIDE. THIS
TIME WITHOUT YOU HAS BEEN ETERNAL. I INVITE YOU TO THE ZOO ONE TO
SEE THE ZEBRAS AND GORILAS.
Check input and AC output for thousands of problems on uDebug!