In the Bay Area for technology careers a bachelors degree is typical. That usually takes people 4 years in a university, however it's not uncommon for people to take 5 years. Some people decide to get additional education after there bachelors degree and go for a masters degree. A masters usually takes 2 years, but for some people it could take 3 years.
In non-technology careers there can be less demand and getting a masters degree will be a competitive advantage for an individual applying to the same job as a lot of other people. And usually more important is getting experience doing projects outside of class or internships that give you direct experience in the type of work you are pursuing.
The type of degree you go for and number of years it takes is dependent on the type of career you want to pursue and how much time you can dedicate to school. For me, I wanted to get into engineering. For the Bay Area a bachelors degree is good unless you are passionate about a specific technology and want to specialize in it. I worked part time at the same time went to school full time at a University of California school. I was able to finish in 4 years but it took a lot of hard work.
Trying to decide what degree you want to pursue is a difficult decision for most people. However, getting a degree is the most important thing, even if you're not sure what you want to do for the rest of your life. If you're not sure what you want to do try to take as many different type of classes as you can both before college and during college.