Equal pay for all was never the reality in the Soviet Union. There were distinct socio-economic classes. Communist Party bigwigs, skilled professionals, high profile artists and writers, military officers, all got "paid" more than common workers (often in the form of perks and privileges), sometimes got more rations, got nicer houses/apartments, got cars and maybe even drivers, got to shop in special stores with better stuff than was available to masses, with no waiting in the long lines that characterized daily life for the average citizen. So there was plenty of incentive to do well in school and try to become a doctor, engineer, etc. (sources off the top of my head: Klass: How Russians Really Live by David Willis, Everyday Stalinism by Sheila Fitzpatrick). Of course it is much more complex than this and the specifics evolved over time with different leaders and economic reforms, but the "communist" Soviets never managed to achieve Marx's classless society.