Hi there!
AP classes are college leveled classes offered to high school students to have the chance to earn AP credit.
If a student decides to take an AP class, they will learn college level material in class during school. At the end of the year (typically an May) students take the AP exam, if the student scores above a 3 they receive college credit. HOWEVER, the score a student gets on an AP exam does not guarantee college credit. It all depends on the college. For example, if you plan to apply to Harvard a perfect 5 on the test will not earn you any credit. But if you apply to a college like ASU getting a 3 may get you some credit whereas a 4 may get you exempted from taking the course in college. It all depends on the college. Lastly, you do not need to take an AP class to take an AP exam. I hope this helps, you may comment on this if you have further questions!