We'll go over for installation on Windows in Linux using XAMPP/LAMPP - but we won't go over MAMP or XAMPP for Mac as I have no experience with it. XAMPP/LAMPP is open source and free of charge, so no worries about having to purchase anything :)
XAMPP/LAMPP comes with Apache, PHP, MySQL, Perl, SQLite, phpMyAdmin, OpenSSL, GD w/FreeType, and much more - so it should have everything you need for development.