Can you take Pre-med classes at a CC instead of a 4 year uni and still get into a good Med School?

@ucbalumnus I live in the Bay Area, and I have to stay here, so any college around here. Also, something around 20k or less after grants is the cost I can afford.