That depends on demand/supply. Tech companies in cities with high demand for engineers have no problem hiring people who will leave as soon as something better shows up.
That is subtly different from what I wrote. :) I wrote that no one who were open about it would be unable to find a job. If you told your interviewer that your only objective is to maximize salary they would (rightly) treat you as a sociopath. A company whose only objective is to minimize salaries (and therefore maximize profits) is also a "sociopath" but that is somehow acceptable.
Yeah, that's true, I guess you'd normally wouldn't say that. Although I've worked a guy once that said something similar and got hired anyway. He still works in the same place after a couple years and still has the same attitude. I think that most people make it up to be a lot less socially acceptable than it actually is.