Skip to content

Instantly share code, notes, and snippets.

@minnacaptain
Last active Jul 26, 2021
Embed
What would you like to do?
Parse the example data
const getContent = () => Deno.readTextFile('./example_data.txt')
const calculateAverageScore = (getContent: () => Promise<string>) => getContent().then(result => {
const lines = result.split("\n").map(l => l.split(","))
console.log(lines)
})
calculateAverageScore(getContent)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment