The SAS program creates a data set with the student names and scores, uses PROC MEANS to calculate the mean and sum for each student, and outputs the results in two tables. Data _null_; input Names $ Subject Score; cards; John Math 90 John English 96 John French 87 John Physics 45 John History 77 Mary Math 80 Mary English 60 Mary French 87 Mary Physics 65 Mary History 66 Dick Math 78 Dick English 78 Dick French 56 Dick Physics 34 Dick History 88 Lucy Math 74 Luc