I hear alot about how unreliable bmws are. But are they really?

Speaking to people who have actually owned bmws, im looking to buy a 335xi. I hear alot of back and forth bmws are good bmws are bad. Hows your experience been with them? And would it be more reliable getting a crosstrek instead of the bmw?