Mendeleev classified the elements on the basis of increasing atomic masses. So accordingly lithium with lesser mass is succeded by beryllium with higher atomic mass. In other cases, calcium has more atomic mass than potassium, nickel is heavier than cobalt and nitrogen is heavier than carbon.