@nixCraft now if you were on an instance that allows the ```…``` fenced Markdown code blocks, you’d be fine posting that.
But not without. Your toots are transmitted as HTML over AP, and without a <pre> tag in that, will neither preserve whitespace nor be rendered in an appropriate font, so if you’re on Mastoson, you cannot post such things.