Added root cost as 1/2 average character length--list access for character length, perhaps convert ot vector