×

Doubt in Traverse problem of Innerve's summer code challenge.

 0 Where this logic is giving wrong answer??? Traverse problem of innerve.... while(t--){ scanf("%d",&m); if(m%3 == 0){ printf("%d %d\n",m/3,2*(m/3)); } else{ double n=m; i=ceil(n/3); j=i-1; while(j<2*i){ if(i+j == n) { goto label; } j++; } label: printf("%d %d\n",i,j); }  } return 0; asked 27 Jul '17, 16:36 2★jaina15 3●2 accept rate: 0%

 0 @jaina15 Your code is working fine. check out here: https://www.codechef.com/viewsolution/15220747 Just copy and paste. answered 02 Sep '17, 18:10 16 accept rate: 10%
 toggle preview community wiki:
Preview

By Email:

Markdown Basics

• *italic* or _italic_
• **bold** or __bold__
• 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:

×3,820
×1,191
×890
×181

question asked: 27 Jul '17, 16:36

question was seen: 332 times

last updated: 02 Sep '17, 18:10