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.
This makes more sense than the "'*' approach" mentioned in a (very) long stream of commments here, because the Idea is to "use the print function". I'd condense it a bit:
[print(i+1,end='')foriinrange(n)]
(The "'*' approach" is way more elegant, though :))
Cookie support is required to access HackerRank
Seems like cookies are disabled on this browser, please enable them to open this website
Print Function
You are viewing a single comment's thread. Return to all comments →
This makes more sense than the "'*' approach" mentioned in a (very) long stream of commments here, because the Idea is to "use the print function". I'd condense it a bit:
(The "'*' approach" is way more elegant, though :))