Before buying a used car from a dealership, ask to have it looked over by a third-party mechanic.
If the dealership says no, go somewhere else. Your mechanic might be able to tell you if the car is any good or not. https://tireless-antelope-krdntp.mystrikingly.com/blog/auto-repair-tips-that-are-certain-to-help-fix-your-car-problems