Compare fractions with the same top or the same bottom number