Of the two options given, I've gotta say Super Mario 3. Though World has slightly tighter controls and prettier graphics, 3 has the better levels and the powers feel better and are more diverse. Both have excellent level design(though personally, I feel 3's is a bit better), both have great enemy diversity, and both have a great difficulty.
They're both stellar games, but 3 is just about perfect in my opinion. Though that's pretty fiercely laced with nostalgia, as I literally grew up playing Mario 3 as a family game, so I have ridiculously high reserves of fond memories attached to it. By the time my family got a SNES, I was the only one really into playing video games.
Though to be honest, I still prefer Yoshi's Island over SMW.
Aaaand now I have to go hook up the SNES and dig out Mario Allstars and World 1+2.