I want to know whether the following sentence is complex or compound.
We must not be late, else we will miss the train.
If I had to pick one or the other, I'd say it's a complex sentence since the two parts of the sentence are not truly independent of each other. The second part is offered as a hypothetical consequence of the first part.
However, it could easily be restructured as a compound sentence:
We must not be late, as we don't want to miss the train.
This expresses two related but separate thoughts.