change ifs to else ifs