All 255.255.255.224,255.255.255.240,255.255.255.248,255.255.255.252,255.255.255.254 are correct Direct broadcast address for given question X.X.X.31 as it has 31 as broadcast so it can have last octet subnet address as :- 0 (255.255.255.224),16(255.255.255.240),24(255.255.255.248),28(255.255.255.252),30 (255.255.255.254) but only in given option with maximum 1's it is option A.Even your answer 255.255.255.224 is correct as well as option A.I think its ambiguous question.