Contribution - Disable imports?

I’m attempting to make a simple recursion-based I/O puzzle as a contribution, but some imports would provide shortcuts or even full solutions to the puzzle instead of making users implement their own solution. Is there any way to disable/block code using imports from being accepted as a valid solution?