I did some digging, and it appears the two main sources for Jetpunk's urban area population quizzes (demographia and citypopulation) list São Paulo's population as around 23,000,000. On both websites this puts São Paulo higher than they list New York City (with Lagos lower than both of them). However, 23,000,000 seems to correspond to the population of the "Greater São Paulo" metropolitan area rather than the megalopolis "São Paulo macrometropolis". This seems consistent, as using the extended figure would (allegedly) be like counting Boston as part of NYC (both part of the Northeast megalopolis). While the macrometropolis definitely touches the ocean, the Great São Paulo metropolitan area itself doesn't quite reach it, as can be seen in this image:
Slightly disappointed that the Azores are the third-least guessed answer. Then again, maybe I shouldn't be, because if more people knew about them, they'd all flock there for their holidays, because it's a stúnning part of the world.
Not my usual performance.
Lagos also directly touches the coast and is more populated than New York.
https://commons.wikimedia.org/wiki/File:S%C3%A3o_Paulo_satellite_image,_Landsat-5_2010-04-18_(cropped).jpg