I ride a lot less these days than I used to. I used to ride “off road” on a 36, a 26 and a 24. There are noticeable differences even between the 24 and the 26.
The sizes are nominal: a 26 may be have a slightly smaller or larger diameter than 26 inches, depending on the tyre choice. However, if you take the two measurements as exact, then a 26 is 26/24 as big as a 24; that is 8.3% bigger.
8.3% is less than the typical difference between gear ratios on a bicycle. When I had a touring bike, I set it us so that the gears were as near as possible to 10% apart.
So in a sense, the choice between 24 and 26 is less significant than the choice between 7th gear and 8th gear on a road bike: which is better depends on the situation.
However, it isn’t that simple. The larger wheel rolls over stuff better. This is particularly important if you ride “off piste” through long grass, deep mud or undergrowth. A Coker will ignore stuff that would stop a 24 in its tracks. A 26 will “smooth out” stuff that a 24 would make into hard work.
On firm hard track, the 26 will be about 8% faster (assuming identical cranks and cadence) and that extra speed is noticeable on a long trip. It also gives you more momentum, and you can sometimes “rush” a short steep obstacle on a 26 when the 24 would stall just before the top. There is a double effect here because the 26 can maintain its speed better over small bumps that might put you off your stride on a 24, so the 26 is less likely to stall during the “rush”.
But the 24 wins out on tight turns on winding tracks between trees or rocks. It feels very much more manoevreable.
Assuming identical cranks, the 26 will have an extra inch of ground clearance, which makes a real difference to whether or not you suffer the indignity of a pedal strike-induced UPD.
On the other hand, assuming identical cranks, the 24 will be easier on the knees on steep descents. It will be that bit easier to idle or reverse, and will generally be more responsible to sudden attempts to change speed. The feeling I have is that the 26 is great while you can keep it rolling, but once you get bogged down, the 24 is easier to restart.
Freemounting the 24 is far easier - a big difference if you are tired - and UPDs are slightly less painful because you are generally travelling more slowly and nearer to the ground. This is mainly psychological, because the extra height of the 26 is only an inch, but there is definitely an effect there.
The 26 has a wider range of tyres because 26 is a common mountain bike tyre size. However, the 24" tyres tend to be more specialised with higher volume.
Weight is an issue. 8% larger diameter means 8% heavier rim and tyre (other things being equal).
On the whole, I’d prefer 24 for MUni, and 26 for cross country, but it is only a question of emphasis, not a fundamental difference.