By the end of this year, .... in this town for eleven years
Explanation
The correct option is D. The statement 'By the end of this year, i will have lived in this town for eleven years' is a future perfect tense. A future perfect tense is a combination of future time and the present perfect tense. This means, the speaker has been living and still lives in the town, and by the end of the year it will be eleven years since he started living in the town.
This phrase ''will + have'' shows an action or event that started in the past, is starting or will start in the future and that will also be completed at some future time.
For instance, At 2:30 tomorrow afternoon, I will have finished my third class. (My classes won't begin until tomorrow morning and they won't finish until tomorrow at 2:30 PM.)