You are not logged in. Please login at www.codechef.com to post your questions!

×

uncle johny

http://www.codechef.com/problems/JOHNY

here is my solution to above problem, i know it is different from most of the correct answers i went through but i could not find a case where the code is going wrong. HELP TO FIND ONE. i checked many test cases by running the accepted solutions in my pc all matched with my answers.

http://www.codechef.com/viewsolution/6402747

asked 07 Mar '15, 01:09

rishu97kr's gravatar image

2★rishu97kr
2527
accept rate: 0%


1
10
1 2 3 4 5 6 7 8 9 10
4

For this test case your program doesn't take the last input i.e 4
If I am wrong anywhere do prompt me


HAPPY CODING

link

answered 07 Mar '15, 08:39

nickzuck_007's gravatar image

3★nickzuck_007
191621
accept rate: 14%

no its working f9... after taking the last input 4 it is correctly showing answer as 4.

(07 Mar '15, 16:00) rishu97kr2★

Ooops .......SORRY for that ...Try with this test case
1
10
1 3 2 4 6 5 8 7 10 9
4

(08 Mar '15, 13:31) nickzuck_0073★

again correct... showing answer 4

(09 Mar '15, 21:58) rishu97kr2★

I am sorry Bro !! I don't find any problem with this .... I guess @damn_me / @betlista / @pratku123 might help you

(15 Mar '15, 09:50) nickzuck_0073★
toggle preview
Preview

Follow this question

By Email:

Once you sign in you will be able to subscribe for any updates here

By RSS:

Answers

Answers and Comments

Markdown Basics

  • *italic* or _italic_
  • **bold** or __bold__
  • link:[text](http://url.com/ "title")
  • image?![alt text](/path/img.jpg "title")
  • numbered list: 1. Foo 2. Bar
  • to add a line break simply add two spaces to where you would like the new line to be.
  • basic HTML tags are also supported
  • mathemetical formulas in Latex between $ symbol

Question tags:

×2,698
×1,371
×931
×75

question asked: 07 Mar '15, 01:09

question was seen: 1,594 times

last updated: 15 Mar '15, 09:52