Macbook pro will not connect to wifi?
On my MacBook Pro I sometimes had similar difficulties. It always turned out that the cause were weak signals or interferences. Please try the following measures:


Move your Mac closer to the WiFi Router / Airport. Alternatively place your router in a better spot (e.g. elevated). 
Change our Wifi from the 2.4 GHz to the 5 GHz band (If you provide more info on your router, I might be able to give more info on how to do that)
Try to look for other devices that could cause interferences like TVs, bluetooth devices, microwaves.
If you have to use the 2.4 GHz band, try switching to a different channel. See what channel the WiFis around are using and choose a channel number that is farthest away from the others. Ideally select channel 1, 6, or 11.


You can analyse your WiFi environment pressing alt and your WiFi icon in the MenuBar. You will get some info like this. If you hover the mouse over other network names you also get information about those.



This article, for example, has more info on the issue.