293 @verb #3309:"expanded_seatedlist_msg" this none this rxdo #8438 @program #3309:"expanded_seatedlist_msg" this none this "Expand %g to the correct descriptive phrase, like a pronoun substitution." who = args[1] which = args[2] message = args[3] chair_count = this.seatlist[which][2] english_chair_count = $string_utils:english_number(chair_count) person_count = length(who) english_person_count = length(who) ? $string_utils:english_number(length(who)) | (chair_count == 2 ? "either" | "any") phrase = person_count < chair_count ? english_person_count + " of the" | "the" message = $string_utils:subst(message, {{"%g", phrase}}) return message . 0