1 Corinthians 5:10 (ESV)

10 not at all meaning the sexually immoral of this world, or the greedy and swindlers, or idolaters, since then you would need to go out of the world.

From Paul’s previous letter, the Corinthians evidently concluded that he was asking them to avoid all sexually immoral people (as well as all the greedy, swindlers, and idolaters).

Of course (as Paul points out himself), such a command would be impossible to observe. This is not at all what he meant. The church lives in the world and cannot (in fact, should not) avoid contact with people of the world.