Used unsigned int for node degree.