Per IRS Publication 970, Tax Benefits for Education, page 11:
Generally, you can claim the American opportunity credit if all three of the following requirements are met.
Page 23:
Generally, you can claim the lifetime learning credit if all three of the following requirements are met.
Page 40:
Generally, you can claim the tuition and fees deduction if all three of the following requirements are met.
Note that any link in the information above is updated each year automatically and will take you to the most recent version of the webpage or document at the time it is accessed.