Scouto interview question

test cases find the valid IP Adress