Just 2 cent notes to Howards response ... due to begining version and destination.
Check addons installed in the 2.4.x for compatibility through the versions to destination. moosh is a handy tool for that.
Any customized code?
After each stage of the 'march', make a backup of code and DB for sure so you don' t loose ground just in case there is a hickup with the next step upwards. Consider the moodledata directory should also be backed up for a full site ... however, on a site that has been used, that directory could be massive and require quite a bit of space to archive at each stage ... so also consider using rsync for moodledata. Minimally, do filedir alone.
Upgrading php to 7.0.x can take place *after* reaching 3.0.highest - not before.
'spirit of sharing', Ken