An exam tests your ability to hold information, and produce it later. Not relevant to every subject, I'll agree, but a useful life skill. In coursework, you can research as you go. Life doesn't always give you the opportunity, and exams are good practice at that.