Modified firstChar function.