Not mine entirely, mostly stolen from a stackoverf...
# random
d
Not mine entirely, mostly stolen from a stackoverflow thing I found and converted to Kotlin