Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- type Result = [String]
- pp :: Result -> IO ()
- pp x = putStr (concat (map (++"\n") x))
- strReplace :: String -> Int -> Char -> String
- strReplace [] _ _ = []
- strReplace (x:xs) i c =
- if (i == 0)
- then c : strReplace xs (i-1) c
- else x : strReplace xs (i-1) c
- res :: Result
- res = [ "8........",
- "7........",
- "6........",
- "5........",
- "4........",
- "3........",
- "2........",
- "1........",
- " abcdefgh"]
- chess :: [String] -> [String] -> Result
- chess x y =
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement