Correct option is B
Given:
Only one of them is the landlord, whose apartment is at one end.
Ramesh's apartment is not next to John's apartment.
The apartment on the left is not the landlords,
The one in the middle is not Ramesh's and
The one on the right is not John's.
Solution:
According to the question,
Ramesh's apartment is not next to John's apartment, therefore,
Umar's apartment is in middle.
But the landlord's apartment is not on the left or middle, therefore
his apartment is on the right.
Clearly, John's apartment is on the left,
Try this setup:
Check:
· Landlord = Position 3 → ✔️ (Ramesh)
· Ramesh is not in middle → ✔️
· John and Ramesh are not adjacent → ✔️
· Right is not John → ✔️
· Left is not landlord → ✔️
All conditions are satisfied
!
∴ The landlord is Ramesh