How do they rank college basketball teams?

by wins and losses, and the games they have had, that is why North Carolina is higher ranked than Memphis, cause they have a lot more harder games to play