Firstly, we must learn that these are two separate APIs.
The first one which is MapRed is used in Hadoop version 1 which is
org.apache.hadoop.mapred
and the second was used in Hadoop version 2 where YARN was introduced and that version of API was called as MapReduce.