How do I group by and display only first row of each group?
If you are using D7 - View Merge Rows module can provide the functionality that you need.

In your scenario, select field subject as Grouping field Nr.1.

Access Merge setting in Advanced section of your View. 



For the Subject field - select the setting "Use values of this field as a filter".

For the Due_Date field - select the setting "Use the first value of this field".

If your View contains more than two fields, you will need to select the settings for Merge rows to accommodate processing of added fields.