I think you may be talking about "Dual Credit" classes.
There are some high schools with qualified teachers that teach subjects that qualify for college credit.