Single line code for 3 different checks