Here is one way:
Create a formula field to concantenate the first to fields together called "StudentAndCouse", probably like this:
{Table.studentname} + "-" + {Table.coursecode}
and then group on that formula field.
Now do an insert summary (Sigma sign)
do a Count of @StudentAndCourse with a location on group footer1
Click on the Record Select
Click on on show formula option
Change the toggle to Group Selection
click on formula editor
in the report fields grab the Report area Count field into your formula and make that >1 so you end up with something like
COUNT({@ StudentAndCourse}, {@ StudentAndCourse})>1
Does that give you what you need?