Superconductivity of the magnetized electron gas of a quantum cylinder