rank is now returns by reference, cleaned up strings