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.
There is nothing wrong with this code. The best way you can write is by allocating the size of the array during the run time. The user may need a length that is beyond 100 and in that case, this code ceases to work.
Cookie support is required to access HackerRank
Seems like cookies are disabled on this browser, please enable them to open this website
Arrays Introduction
You are viewing a single comment's thread. Return to all comments →
There is nothing wrong with this code. The best way you can write is by allocating the size of the array during the run time. The user may need a length that is beyond 100 and in that case, this code ceases to work.