Hello!

Short code... Use Assembler.

Compiler - Borland C++ Builder 5.0

.....
 short int A=10;
 short int B=20;
 short int R=0;

_asm{  PUSH BX   // * SAVE BX - if without push/pop - look compiler 
documentation
       PUSH AX   // * SAVE AX
       MOV AX,A
       MOV BX,B  // *
       CMP AX,BX
       JG  L2    // SIGNED ... look another J* commands
   L1: MOV AX,BX // COPY 'B' value to AX
   L2: MOV R,AX  // AX - A or B value
       POP AX    // * RESTORE AX
       POP BX    // * RESTORE BX
}
.....

And short...
 No  - PUSH/POP
 Use - CMP AX,B


Assembler command:
1. IBM PC & XT Assembly Language
   A Guide for Programmers
   (Enhanced and Enlarged)
   Leo J.Scanlon

Лучшие предложения интернет-магазинов на Това�[email protected] 
http://r.mail.ru/cln4267/torg.mail.ru/


------------------------------------

To unsubscribe, send a blank message to 
<mailto:[email protected]>.Yahoo! Groups Links

<*> To visit your group on the web, go to:
    http://groups.yahoo.com/group/c-prog/

<*> Your email settings:
    Individual Email | Traditional

<*> To change settings online go to:
    http://groups.yahoo.com/group/c-prog/join
    (Yahoo! ID required)

<*> To change settings via email:
    [email protected] 
    [email protected]

<*> To unsubscribe from this group, send an email to:
    [email protected]

<*> Your use of Yahoo! Groups is subject to:
    http://docs.yahoo.com/info/terms/

Reply via email to