We use cookies to ensure you have the best browsing experience on our website. Please read our cookie policy for more information about how we use cookies.
Still broken!! Seems like the internal mechanism is counting the number of items in the list, which it uses to assert the test results. So output should be a list so it counts the number of elements. Purchased all test cases and for some wierd reason, even though testcase #1 and #2 fail, seems like #3 and #4 pass, and the output is an integer (total number of elements in the list) just like in the first 2.
...was using IO.inspect without options, thats why it was failing, since inspect does not show the whole list if its too long, passing limit: :infinity to the inspect function's options fixed it. Nice!
Cookie support is required to access HackerRank
Seems like cookies are disabled on this browser, please enable them to open this website
Join us
Create a HackerRank account
Be part of a 26 million-strong community of developers
Please signup or login in order to view this challenge
Array Of N Elements
You are viewing a single comment's thread. Return to all comments →
Still broken!! Seems like the internal mechanism is counting the number of items in the list, which it uses to assert the test results. So output should be a list so it counts the number of elements. Purchased all test cases and for some wierd reason, even though testcase #1 and #2 fail, seems like #3 and #4 pass, and the output is an integer (total number of elements in the list) just like in the first 2.
...was using
IO.inspect
without options, thats why it was failing, sinceinspect
does not show the whole list if its too long, passinglimit: :infinity
to the inspect function's options fixed it. Nice!