Sign up at OpenWeatherMap to get a free API key.
We will use libcurl to make HTTP requests. Install libcurl if you haven't already:
- On Ubuntu:
sudo apt-get install libcurl4-openssl-dev
- On macOS:
brew install curl
Execute:
g++ -o weather_app main.cpp -lcurl
./cpp-weather-app