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.
Actually val lines = stdin.getLines().drop(1) will give you all lines you need, dropping the first one, which is good enough for this problems. In real life, though, it's better not to do it this way.
Cookie support is required to access HackerRank
Seems like cookies are disabled on this browser, please enable them to open this website
Compute the Perimeter of a Polygon
You are viewing a single comment's thread. Return to all comments →
Actually
val lines = stdin.getLines().drop(1)
will give you all lines you need, dropping the first one, which is good enough for this problems. In real life, though, it's better not to do it this way.