In France, the government sets the number of 2nd year medical school seats available. Anyone can sign up for year 1, but only the top N students at the end of year exam make it to the second year.
This stands in stark contrast with the USA where the AMA calls the shots. In effect, the doctors control the supply of doctors.