A student can increase the chance of making the right choice by trying the college’s old final exams of the courses that are allowed to be skipped with AP credit, if s/he will need to take courses which depend on that course or AP credit as a prerequisite.
Can it be done? Definitely, especially with the BS/MS programs that are common is most universities. It is more difficult to do in engineering, however, because of the large number of sequential required courses . Our son came in with 2nd semester sophomore standing and will take 3.5 years + one 3 credit (capstone) class to finish his BSE (ChemE, 128 credit total), 5 for a MSE. That included a semester abroad where he didn’t get full engineering credit.
Our son had that plan originally but is now leaning toward a Ph.D. , simply because discovered that he likes research and is getting lots & lots of encouragement from the grad students at the research lab where he works. Not that that is a bad thing, especially in engineering, where virtually every position is funded.