Anonymous user
Largest int from concatenated ints: Difference between revisions
m
→{{header|Haskell}}
(→{{header|C}}: replaced with simpler code with total length limitation) |
|||
Line 72:
import Data.Ord (comparing)
main = print (map maxcat [[1,34,3,98,9,76,45,4], [54,546,548,60]] :: [
where sorted = sortBy (flip $ comparing $ cycle
maxcat = read . concat .
{{out}}
|