I had at least 5 undergrad classes where I didn't attend a single class all semester with no penalties whatsoever. I never learned well in a classroom environment, my average grades were probably higher in classes I didn't go to. If I had all mandatory classes I would have transferred.