Elantra is considered one of reliable cars on the market. However, there is
always risk when buying a second hand car.
You might want to check Hyundai website for its warranty. I vaguely remember
Hyundai offer 5-year basic warranty that covers many items. I think it's
transferable but it's better to double check.
The 10 year warranty on power train is not transferable.