sometimes a picture helps ...
Greetings Mike ...
let's assume (gosh I hate that word) that you're talking about an Allen-Bradley system ...
here's the first part of your question:
when scanning program goes from left to right and top to bottom
unfortunately that is NOT absolutely correct ... rather than go through a lot of mumbo-jumbo about what actually DOES happen as the processor executes the rung, I suggest that you use the ASCII (mnemonic) mode in RSLogix to display your rung and track down the actual instruction-by-instruction sequence of execution ... this is the technique that bluebyu was recommending in his post (above) ...
I've posted an example figure below that might be helpful ... you might also want to take a look at post #20 in this thread:
http://www.plctalk.net/qanda/showthread.php?p=98323&postcount=20
secret handshake: for your purposes, you can just skip over any "branch-type" instructions (BST, NXB, and BND) and simply concentrate on how the PLC processor executes everything else ...
going a little bit further ... you went on to ask the following:
but what happens when there is a branch on the output. Does the top part of a branch on output get turned on and then next scan unlatch if you want like a one shot? or is this possible?
I'm not sure that I understand what you're asking there, so if you're still having problems after all of the dust settles, I suggest that you post again with some more detail – and ideally a screen shot of whatever rung construction is confusing you ... I'm sure that the forum members can help you sort it all out ...
also ...
something about the way that you phrased your question leads me to think that you might have some serious misconceptions about exactly what is going on during the processor's scan sequence ... (believe me, you would NOT be alone) ...
my point is this:
no offense intended, but if you think that the "outputs" on your rung (specifically the OTE, OTL, OTU instructions) are actually "turning things ON or OFF" - or else "latching things ON" - etc. then you're making ladder logic a lot harder to understand than it needs to be ... there's a MUCH easier way to look at the PLC's operation than that – and fortunately that easier way happens to be more accurate too ... if you're confused by any of this, then I recommend that you watch the series of YouTube videos available on the "Sample Lessons" page of my website ... you should watch these IN ORDER and see if the basic information there helps you gain a better understanding of what's actually going on "under the hood" of an Allen-Bradley PLC ...
I hope this helps ...