Optocouplers common resistor
simulate this circuit &ndash; Schematic created using CircuitLab

Figure 1. OP's schematic redrawn.

In Figure 1a a typical LED wired as shown would receive a current of about \$ I = \frac {24 - V_f}{480} = 45 \ \text {mA} \$ if the forward voltage, Vf is about 2 V.

In the Figure 1b the same current will result if one LED is switched on. If two are switched on they will receive about half the current, three -> one third, etc.

A further problem will occur due to variation in the Vf of the various LEDs. The one with the lowest Vf will hog the current, get hotter, its Vf will decrease, causing it to hog more current, etc., and may fail. For more on the topic see what I've written in LED variations and binning.