In the given reaction
(X), X will be :

From the Halogen Derivatives · Practice set paper. Try it, check your answer, then read the worked solution below.
In the given reaction
(X), X will be :

Try it yourself first, then check your working against this.
No worked solution for this one yet.
Concepts used: intramolecular SN2, thiolane formation
Every past question tagged to the same part of the syllabus, with solutions.
Past questions on the same topic (SN1 and SN2), each with a worked solution.
Timed, in the real format, and marked the moment you submit.