get rid of capitals

This commit is contained in:
Felix Van der Jeugt 2021-12-03 08:04:04 +01:00
parent 1f013dc0c3
commit 3db67bd012
No known key found for this signature in database
GPG key ID: 58B209295023754D
6 changed files with 0 additions and 0 deletions

7
day00/part1.hs Normal file
View file

@ -0,0 +1,7 @@
import System.IO (readFile)
import System.Environment (getArgs)
main :: IO ()
main = do [_, _, file] <- getArgs
(_:numbers) <- map (read :: String -> Int) . lines <$> readFile file
putStrLn $ show (minimum numbers) ++ " " ++ show (maximum numbers)

8
day00/part1.lua Normal file
View file

@ -0,0 +1,8 @@
io.input(arg[3])
local min, max = math.huge, -math.huge
for i = 1, io.read("*n") do
local num = io.read("*n")
max = math.max(num, max)
min = math.min(num, min)
end
print(min .. " " .. max)