From the SE ToS, which is probably relevant:
3. Subscriber Content
You agree that all Subscriber Content that You contribute to the Network is perpetually and irrevocably licensed to Stack Exchange under the Creative Commons Attribution Share Alike license. You grant Stack Exchange the perpetual and irrevocable right and license to use, copy, cache, publish, display, distribute, modify, create derivative works and store such Subscriber Content and, except as otherwise set forth herein, to allow others to do so in any medium now known or hereinafter developed (“Content License”) in order to provide the Services, even if such Subscriber Content has been contributed and subsequently removed by You. Subscriber warrants, represents and agrees Subscriber has the right to grant Stack Exchange and the Network the rights set forth above. Subscriber represents, warrants and agrees that it will not contribute any Subscriber Content that (a) infringes, violates or otherwise interferes with any copyright or trademark of another party, (b) reveals any trade secret, unless Subscriber owns the trade secret or has the owner’s permission to post it, (c) infringes any intellectual property right of another or the privacy or publicity rights of another, (d) is libelous, defamatory, abusive, threatening, harassing, hateful, offensive or otherwise violates any law or right of any third party, (e) contains a virus, trojan horse, worm, time bomb or other computer programming routine or engine that is intended to damage, detrimentally interfere with, surreptitiously intercept or expropriate any system, data or information, or (f) remains posted after Subscriber has been notified that such Subscriber Content violates any of sections (a) to (e) of this sentence. Stack Exchange reserves the right to remove any Subscriber Content from the Network, re-post to the Network any Subscriber Content removed by any Subscriber or former Subscriber, suspend or terminate Subscriber’s right to use the Services at any time, or pursue any other remedy or relief available to Stack Exchange and/or the Network under equity or law, for any reason (including, but not limited to, upon receipt of claims or allegations from third parties or authorities relating to such Subscriber Content or if Stack Exchange is concerned that Subscriber may have breached the immediately preceding sentence), or for no reason at all.
In the event that You post or otherwise use Subscriber Content outside of the Network or Services, with the exception of content entirely created by You, You agree that You will follow the attribution rules of the Creative Commons Attribution Share Alike license as follows:
You will ensure that any such use of Subscriber Content visually displays or otherwise indicates the source of the Subscriber Content as coming from the Stack Exchange Network. This requirement is satisfied with a discreet text blurb, or some other unobtrusive but clear visual indication.
You will ensure that any such Internet use of Subscriber Content includes a hyperlink directly to the original question on the source site on the Network (e.g., https://stackoverflow.com/questions/12345)
You will ensure that any such use of Subscriber Content visually display or otherwise clearly indicate the author names for every question and answer so used.
So yes, people can reuse your code, so long as they put it under the same license terms as SE granted it to them under.