I do not understand why these two loops are different.  It must have something to do with when the brace expansion is performed and how white space is interpretedfor i in b{e,\ }s ; do echo $i ; donefor i in bes b s ; do echo $i ; doneand consider this toofor i in $(echo b{e,\ }s) ; do echo $i ; done
Brace expansion and compound command
shell;brace expansion