The Expanse briefly mentions this in one of the books. Earth has universal "basic" income but if people want to go to university they have to do 2 years of working less desirable jobs to show they can handle working.
I heard that Starship Troopers book had something like what you described but I haven't read it.