In 1919, Ulam entered Lwów Gymnasium Nr. VII, from which he graduated in 1927. He then studied mathematics at the Lwów Polytechnic Institute. Under the supervision of Kazimierz Kuratowski, he received his Master of Arts degree in 1932, and became a Doctor of Science in 1933. At the age of 20, in 1929, he published his first paper Concerning Function of Sets in the journal Fundamenta Mathematicae. From 1931 until 1935, he traveled to and studied in Wilno (Vilnius), Vienna, Zürich, Paris, and Cambridge, England, where he met G. H. Hardy and Subrahmanyan Chandrasekhar.