Just plug it in. Some games will allow you to select the monitor but most don't so you'll have to select the 24" as the primary monitor in Windows.
Some games allow you to set the 'default' monitor in the settings, for ones that don't you'd have to make your 24" your default in Windows before firing the game up.
I have this exact set up, a 1440 as my main and an old 1080 as my second screen. Running with a GTX-1070 and never had any issues