How do i unlock a test case when it's hidden?? | Sololearn: Learn to code for FREE!

0

How do i unlock a test case when it's hidden??

6/20/2021 2:57:43 PM

Gee Pebbles

10 Answers

New Answer

+3

Gee Pebbles You did opposite division. You have to get hours so divide distance with average so It should be time = 7425 / 550 print (time)

+4

You cant unlock the hidden test case, but if you write the right code you will pass the test. Do you pass test? If not show your code.

+3

Gee Pebbles Generic logic means which satisfy all condition for different inputs. For example if we have inputs 2 and 3 then multiplication should be 6. If we have inputs 4 and 5 then multiplication should be 20. So for above two cases we can write Hard Code logic means we can print like this print (2 * 3) print (4 * 5) But if there are thousands test cases then it is not possible to write for every test case so for this we will write generic logic which will take inputs from user and gives result according to that. So we can write Generic logic like this: num1 = int(input()) num2 = int(input()) print (num1 * num2)

+3

Oh ok Thanks 🙂🙂

+2

Gee Pebbles If you write generic logic then all test cases will be pass.

+2

But what is generic logic??

+2

Thank you!!🙂

+2

Gee Pebbles This is the link of problem. We can't see your code here.

+2

time = float(550 / 7425) print (time) This is it

+1

https://www.sololearn.com/coach/1018?ref=app This is the code