Nonexistence of rational points on certain varieties