Hexagony, 91 bytes
Thanks for the bounty :)
Wow, I would never have imagined I could beat Martin’s Hexagony solution.
But—who would have thunk it—I got it done. After several days of failure because ...
Minecraft 1.10, 221 characters (non-competing)
See, this is what we have to deal with when we make Minecraft maps.
Aside: There's no way to take a string input in Minecraft, so I'm cheating a bit by ...