# Commits

committed a5b763b

Better output for splitter.ml.
Add the input file for splitter.ml.
Try to play nice with Bitbucket's Markdown parser.

• Participants
• Parent commits 196d261

# Files changed (3)

` 	per-line. Read in the integers, sort them and print them out in sorted order`
` 	(on a single line). Name your program _splitter.ml_.`
` `
`-	The basic steps in the algorithm are:`
`-	- Read input into a list.`
`-	- Print the input list.`
`-	- Call a function, splitter, which takes the input list and splits it into two lists. One list will contain all of the even numbers from the input file and the other contains all of the odd numbers.`
`+	The basic steps in the algorithm are:  `
`+	- Read input into a list.  `
`+	- Print the input list.  `
`+	- Call a function, splitter, which takes the input list and splits it into two lists. One list will contain all of the even numbers from the input file and the other contains all of the odd numbers.  `
` 	- Print out both the even and odd lists.`
` `
` 	This program can be implemented without using any assignment statements.`

`+0`
`+1`
`+2`
`+3`
`+4`
`+5`
`+6`
`+7`
`+8`
`+9`
`+10`
`+11`
`+12`
`+13`
`+14`
`+15`

# File splitter.ml

` let ilist = fr ic [] in `
` let e,o = splitter ilist [] [] in`
` `
`-print_endline (String.concat " " (List.map string_of_int ilist));`
`-print_endline (String.concat " " (List.map string_of_int e));`
`-print_endline (String.concat " " (List.map string_of_int o))`
`+print_endline ("Input: " ^ String.concat " " (List.map string_of_int ilist));`
`+print_endline ("Evens: " ^ String.concat " " (List.map string_of_int e));`
`+print_endline (" Odds: " ^ String.concat " " (List.map string_of_int o))`