ΥڡϤƤʥ֥åޡɲΥڡޤϤƤʥ֥åޡ Υڡlivedoor åפɲΥڡޤlivedoor å

ܼ

ˤ껻

껻ξ;ѤƵ뤳Ȥ롣㤨С175ᾦ3;2פȤʤ뤬Τ褦˰򤹤Ф褤

17-5=12
12-5=7
7-5=2ʤ줬;

ưȤʤ롣

CASLξ

  1
  2
  3
  4
  5
  6
  7
  8
  9
 10
 11
 12
 13
 14
 15
 16
 17
SMP0312   START     
          LAD       GR1,0
          LD        GR3,A
          LD        GR7,B
LOOP      CPA       GR3,B
          JMI       STEP
          SUBA      GR3,GR7
          LAD       GR1,1,GR1
          JUMP      LOOP
STEP      ST        GR1,SYO
          ST        GR3,AMARI
          RET       
A         DC        17
B         DC        5
SYO       DS        1
AMARI     DS        1
          END       

®

ɮμץಽ뤳Ȥǹ®ʳ껻ǽȤʤ롣

CASLξ

㡧M(A)M(B)ᡢ٥ȤSYOAMARI¸ߤϤˤ줾껻η̤ξ;Ǽ롣

  1
  2
  3
  4
  5
  6
  7
  8
  9
 10
 11
 12
 13
 14
 15
 16
 17
 18
 19
 20
 21
 22
 23
 24
 25
 26
 27
 28
SMP0331   START     
          LD        GR1,A
          LD        GR2,B
          LD        GR3,=#0001
LOOP1     CPA       GR1,GR2
          JMI       S1
          SLL       GR3,1
          SLL       GR2,1
          JUMP      LOOP1
;
S1        LAD       GR4,0
LOOP2     CPA       GR1,GR2
          JMI       S2
          ADDA      GR4,GR3
          SUBA      GR1,GR2
S2        SRL       GR2,1
          SRL       GR3,1
          CPA       GR1,B
          JPL       LOOP2
          JZE       LOOP2
STEP      ST        GR4,SYO
          ST        GR1,AMARI
          RET       
A         DC        58
B         DC        5
SYO       DS        1
AMARI     DS        1
          END       

Υץǡ585פͤƤߤ롣2ʿɽȡ111010101פȤʤ롣

LOOP1LOOP22ĤΥ롼פ롣
ԤϾκǽ1Ωİ֤Ĥ뤿Υ롼פǤ롣101򺸤1ӥåȤĥեȤơ111010뤫ɤåȤǤ礭ͤ롣ºݤɮοޤ򸫤ƤߤФ狼뤬101פ4ӥåȥեȤ1010000פϡ111010פȤǤʤΤǡ롼פ򤳤ȴ롣
Ԥϱ1ӥåȥեȤʤϰơΤηΰ֤1Ȥ櫓Ǥ롣

  1. 111010פ101000סʡ101פ3ӥåȥեȤΡˤΤǡϡ1000פȤʤ롣
  2. 10000סʤϾ嵭ǰ̡ˤ10100סʡ101פ2ӥåȥեȤΡˤʤΤǡϡ1000פΤޤޤˤʤ롣
  3. 10000פ1010סʡ101פ1ӥåȥեȤΡˤΤǡ1000+10=1010Ȥʤ롣
  4. 1000פ101פΤǡ1010+1=1011Ȥʤ롣

ʸ

  • ؾCASLIICASLIIιֵȼ½[2]