PHP avoids embedded assignment


Avoid the embedded assignment in the following example in the program:
Do not use this method:

while ($a != ($c = getchar())){
    process the character
}