they can be super cheap! mercedes, bmw, audi, even porsche! the reason they have a reputation for being expensive unreliable cars is because is because they make some really fast high strung almost super cars. an m5 or rs4 isnt a good example of bmw or audi reliability. and some years are worse than others. like audi's b5's are usually pretty terrible for reliability, but some of their other cars are tanks.
a mercedes 560 sec, 190 e. bmw's e30 e28, e36, e34, etc... and audi's 90, 4000, etc.. are all super reliable cars, hardly ever break and parts are cheap. but some high strung s4, m3, or amg is not gonna be even close for reliability.