Exp=-
@p1=
@c1=result = Cal_2("@f",@p, 16, @temp_a, @temp_b, @c, @d,KeyPath,2000)
@p2=
@c2=result = Cal_2("@f",@p, 16, @temp_a, @temp_b, @c, @d,KeyPath,2000)
@va=temp_a
@vb=temp_b
@vc=c
@vd=d
ext=prg
mgs=̾ͿڹӸúʹ,ӷɵĺĿ¼£ȻĿѡг,ȻѡҪӵĺ
@end
                                        
&&ú칤ԶɣѡydecreaseȻ󵥻ɣȻɺPRGļڵĿ¼£Ȼڽӵ
&&YDecrease:
&&Ŀģ
&&aҪı1
&&bҪı2
&&ؽĽ
&&LastError=0ȷLastErrorΪμֲ
lparam a , b 
    local b_reverse   &&ֲڴ淴ת
   	local b_negative 
    b_negative = .f. &&ֲڴǷ
    LastError = 0
    &&a,bΪΪ
    If ((a > 0 And b > 0) Or (a < 0 And b < 0)) Then
        If (a < 0 And b < 0) Then
            a = -a
            b = -b
            b_negative = .t. &&Ϊa,bΪȻø
        endif
        &&ֲ
        local temp_a ,temp_b,temp
        &&a256ȡ
        &&ΪʲôҪab256ȡأ
        &&ΪCal_2ʽֻֽڱܳ256
        temp_a = mod(a , 256)
        &&b120ȡ
        temp_b = mod(b, 256)
        &&aȥ&&bȥ
        &&ΪʲôҪֱa,bȥأ
        &&Ϊ׼ڼڲμ㣬a,bҪֱȥԼ
        a = a - temp_a
         b = b - temp_b
        local result,c,d  &&ֲ,ؽ
	c=int(RAND() * 255)
	d=int(RAND() * 255)
        &&жtemp_atemp_bĴС
        &&temp_atemp_bCal_2ĵһΪtemp_a
        &&temp_aСtemp_bCal_2ĵһΪtemp_b
        &&ΪʲôҪأΪڲֻa>bļa<bѭ޷ʹ÷ص
        If (temp_a > temp_b) Then
            &&ⲽa,bĸ͵ڲ,c,dԡ
            &&@fļдмʽ
           @1
            &&ͬʱδת
            b_reverse = .t.
        Else
            &&ⲽa,bĸ͵ڲ,c,dԡ
            &&@fļдмʽ
	temp=temp_b
	temp_b=temp_a
	temp_a=temp
	@1
            &&ͬʱѷת
            b_reverse = .f.
        endif
        If (result <> 0) Then
            LastError = result &&ô
        endif
        &&ڼĽصtemp_a
        &&ٽǰȥa,bͿˡ
        &&ݷתòͬ
        If (b_reverse) Then
            If (b_negative) Then
                return -(a - b + temp_a) &&δתa,bΪ
            Else
                return a - b + temp_a &&δתa,bΪ
            endif
        Else
            If (b_negative) Then
               return -(a - b - temp_a) &&ѷתa,bΪ,
            Else
               return  a - b - temp_a &&ѷתa,bΪ
            endif
       endif
     else
       return a - b
     endif
