Answer: B. 31
Explanation:
First we arrange the given data in a n order , we get
4, 5, 7, 9, 10 ,10, 12, 13, 15, 16, 16 ,17, 18 , 23,31
Lower half of data =4, 5, 7, 9, 10 ,10, 12
First Quartile
= Median of lower half = 9
Upper half of data = 15, 16, 16 ,17, 18 , 23,31
Third Quartile
= Median of upper half = 17
Interquartile range =

Using Interquartile range rule,
Upper limit =

Lower limit =

From the given data , all values lies in the above boundary i.e. all values are greater than -3 and less than 29 except 31 (31>29).
Hence, the outlier for the given data is 31.