Jungle Camping - Code Coach issue (SOLVED!) | Sololearn: Learn to code for FREE!
New course! Every coder should learn Generative AI!
Try a free lesson
+ 8

Jungle Camping - Code Coach issue (SOLVED!)

Hi, folks. A little help, please. I came up with a solution to Jungle Camping in C in Code Campground, tested it and it seemed to work fine. However, in Code Coach, it fails tests 3 and 5, which are hidden, so I have no idea what's wrong. I went through many combinations in Code Playground and all of them worked, so I can safely say I ran out of ideas. Any help from you would be greatly appreciated. Thanks! *Link removed to prevent spoilers.

1st Jan 2020, 8:17 PM
D.R.
D.R. - avatar
5 Answers
+ 5
The task says nothing about how many noises you hear, so there might be more than just three noises. Your solution should cover such cases too.
1st Jan 2020, 9:06 PM
Shadow
Shadow - avatar
+ 4
Awesome, Shadow. Thanks. It seems I'll have to restart from scratch, then.
1st Jan 2020, 9:16 PM
D.R.
D.R. - avatar
+ 4
Sure, good luck with it.
1st Jan 2020, 9:21 PM
Shadow
Shadow - avatar
+ 3
Hi, @Shadow! Just to let you know, if it weren't for your pointing out that the number of noises was not mentioned, I wouldn't have figured that one. As a plus, got to practice a little with string functions in C and now it is working for as many sounds as possible (in a 100-character long string, at least). 😁😁😁 Thank you so much for taking the time to help. By the way, I changed the link on top. Now it points to the real working solution.
1st Jan 2020, 10:07 PM
D.R.
D.R. - avatar
20th May 2020, 4:11 PM
Prashanth K V
Prashanth K V - avatar