I suspect that while the non-US teams are at YC, some of them are technically 'tourists' (i.e just on holiday). They don't need a visa to enter the country so it's a case of hear-no-evil, see-no-evil.
If they decide to stay in the US after YC, then they have to deal with the nightmare of immigration and get themselves proper work permits.
For those who need a tourist visa to even enter the US, I have no idea.
"Seeking investment" is a valid reason to enter the US from visa waiver countries. My (German) co-founder used that when entering for YC and had no problems. It's also a perfectly reasonable simplification of what happens at YC.
It's perfectly legal to enter the U.S. for business reasons, including meetings, conferences or even to raise funding. You're not allowed to become employed by a U.S. corporation, but you can certainly consult for them and do on-site work. I'm a Brit, and I've done all of the above several times under the VWP without border control even batting an eyelid.