first implementation of version comparing