Well... it's a "trick" using lea (load effective address) to "load" edx with edx plus edx times two... As you observe, zero times three is zero. You don't show it, but we then increment edx.. and ,,,

I've never read "Step by Step"... I ASSume Jeff explains this...?

Best,

Frank

I get its a trick but i don't see where the 3 is coming from...

"Not only is this virtually always faster than shifts combined with adds, it’s also clearer from your source code what sort of calculation is actually being done. The fact that what ends up in EDX may not in fact be the legal address of anything is unimportant.LEA does not try to reference the address it calculates.It does the math on the stuff inside the brackets and drops it into the destination operand. Job over. Memory is not touched, and the flags are not affected.Of course, you’re limited to what calculations can be done on effective addresses; but right off the top, you can multiply any GP register by 2, 3, 4, 5, 8,and 9, while tossing in a constant too! It’s not arbitrary math, but multiplying by 2, 3, 4, 5, 8, and 9 comes up regularly in assembly work, and you can combine LEA with shifts and adds to do more complex math and ‘‘fill in the holes.’’ You can also use multiple LEA instructions in a row."

Is there a book you like to recommend? You dont seem to like the book...