请问这个 a怎么算出来,谢谢javascript

问题描述

请问这个 a怎么算出来,谢谢javascript
(function(ab) {
var ad = 2;
var I = 16;
var o = I;
var Q = 1 << 16;
var e = Q >>> 1;
var M = Q * Q;
var T = Q - 1;
var Z = 9999999999999998;
var U;
var aa;
var n, c;

function u(af) {
    U = af;
    aa = new Array(U);
    for (var a = 0; a < aa.length; a++) {
        aa[a] = 0
    }
    n = new b();
    c = new b();
    c.digits[0] = 1
}
u(20);
var J = 15;
var L = q(1000000000000000);

function b(a) {
    if (typeof a == "boolean" && a == true) {
        this.digits = null
    } else {
        this.digits = aa.slice(0)
    }
    this.isNeg = false
}
function r(ai) {
    var ah = ai.charAt(0) == "-";
    var ag = ah ? 1 : 0;
    var a;
    while (ag < ai.length && ai.charAt(ag) == "0") {
        ++ag
    }
    if (ag == ai.length) {
        a = new b()
    } else {
        var af = ai.length - ag;
        var aj = af % J;
        if (aj == 0) {
            aj = J
        }
        a = q(Number(ai.substr(ag, aj)));
        ag += aj;
        while (ag < ai.length) {
            a = g(ae(a, L), q(Number(ai.substr(ag, J))));
            ag += J
        }
        a.isNeg = ah
    }
    return a
}
function P(af) {
    var a = new b(true);
    a.digits = af.digits.slice(0);
    a.isNeg = af.isNeg;
    return a
}
function q(ag) {
    var a = new b();
    a.isNeg = ag < 0;
    ag = Math.abs(ag);
    var af = 0;
    while (ag > 0) {
        a.digits[af++] = ag & T;
        ag = Math.floor(ag / Q)
    }
    return a
}
function x(ag) {
    var a = "";
    for (var af = ag.length - 1; af > -1; --af) {
        a += ag.charAt(af)
    }
    return a
}
var d = new Array("0", "1", "2", "3", "4", "5", "6", "7", "8", "9", "a", "b", "c", "d", "e", "f", "g", "h", "i", "j", "k", "l", "m", "n", "o", "p", "q", "r", "s", "t", "u", "v", "w", "x", "y", "z");

function O(ag, ai) {
    var af = new b();
    af.digits[0] = ai;
    var ah = w(ag, af);
    var a = d[ah[1].digits[0]];
    while (f(ah[0], n) == 1) {
        ah = w(ah[0], af);
        digit = ah[1].digits[0];
        a += d[ah[1].digits[0]]
    }
    return (ag.isNeg ? "-" : "") + x(a)
}
function ac(ag) {
    var af = new b();
    af.digits[0] = 10;
    var ah = w(ag, af);
    var a = String(ah[1].digits[0]);
    while (f(ah[0], n) == 1) {
        ah = w(ah[0], af);
        a += String(ah[1].digits[0])
    }
    return (ag.isNeg ? "-" : "") + x(a)
}
var m = new Array("0", "1", "2", "3", "4", "5", "6", "7", "8", "9", "a", "b", "c", "d", "e", "f");

function R(ag) {
    var af = 15;
    var a = "";
    for (i = 0; i < 4; ++i) {
        a += m[ag & af];
        ag >>>= 4
    }
    return x(a)
}
function B(af) {
    var a = "";
    var ah = V(af);
    for (var ag = V(af); ag > -1; --ag) {
        a += R(af.digits[ag])
    }
    return a
}
function A(al) {
    var ag = 48;
    var af = ag + 9;
    var ah = 97;
    var ak = ah + 25;
    var aj = 65;
    var ai = 65 + 25;
    var a;
    if (al >= ag && al <= af) {
        a = al - ag
    } else {
        if (al >= aj && al <= ai) {
            a = 10 + al - aj
        } else {
            if (al >= ah && al <= ak) {
                a = 10 + al - ah
            } else {
                a = 0
            }
        }
    }
    return a
}
function K(ah) {
    var af = 0;
    var a = Math.min(ah.length, 4);
    for (var ag = 0; ag < a; ++ag) {
        af <<= 4;
        af |= A(ah.charCodeAt(ag))
    }
    return af
}
function W(ai) {
    var af = new b();
    var a = ai.length;
    for (var ah = a, ag = 0; ah > 0; ah -= 4, ++ag) {
        af.digits[ag] = K(ai.substr(Math.max(ah - 4, 0), Math.min(ah, 4)))
    }
    return af
}
function C(am, al) {
    var a = am.charAt(0) == "-";
    var ah = a ? 1 : 0;
    var an = new b();
    var af = new b();
    af.digits[0] = 1;
    for (var ag = am.length - 1; ag >= ah; ag--) {
        var ai = am.charCodeAt(ag);
        var aj = A(ai);
        var ak = k(af, aj);
        an = g(an, ak);
        af = k(af, al)
    }
    an.isNeg = a;
    return an
}
function D(a) {
    return (a.isNeg ? "-" : "") + a.digits.join(" ")
}
function g(af, aj) {
    var a;
    if (af.isNeg != aj.isNeg) {
        aj.isNeg = !aj.isNeg;
        a = S(af, aj);
        aj.isNeg = !aj.isNeg
    } else {
        a = new b();
        var ai = 0;
        var ah;
        for (var ag = 0; ag < af.digits.length; ++ag) {
            ah = af.digits[ag] + aj.digits[ag] + ai;
            a.digits[ag] = ah % Q;
            ai = Number(ah >= Q)
        }
        a.isNeg = af.isNeg
    }
    return a
}
function S(af, aj) {
    var a;
    if (af.isNeg != aj.isNeg) {
        aj.isNeg = !aj.isNeg;
        a = g(af, aj);
        aj.isNeg = !aj.isNeg
    } else {
        a = new b();
        var ai, ah;
        ah = 0;
        for (var ag = 0; ag < af.digits.length; ++ag) {
            ai = af.digits[ag] - aj.digits[ag] + ah;
            a.digits[ag] = ai % Q;
            if (a.digits[ag] < 0) {
                a.digits[ag] += Q
            }
            ah = 0 - Number(ai < 0)
        }
        if (ah == -1) {
            ah = 0;
            for (var ag = 0; ag < af.digits.length; ++ag) {
                ai = 0 - a.digits[ag] + ah;
                a.digits[ag] = ai % Q;
                if (a.digits[ag] < 0) {
                    a.digits[ag] += Q
                }
                ah = 0 - Number(ai < 0)
            }
            a.isNeg = !af.isNeg
        } else {
            a.isNeg = af.isNeg
        }
    }
    return a
}
function V(af) {
    var a = af.digits.length - 1;
    while (a > 0 && af.digits[a] == 0) {
        --a
    }
    return a
}
function H(ag) {
    var ai = V(ag);
    var ah = ag.digits[ai];
    var af = (ai + 1) * o;
    var a;
    for (a = af; a > af - o; --a) {
        if ((ah & 32768) != 0) {
            break
        }
        ah <<= 1
    }
    return a
}
function ae(ak, aj) {
    var an = new b();
    var ai;
    var af = V(ak);
    var am = V(aj);
    var al, a, ag;
    for (var ah = 0; ah <= am; ++ah) {
        ai = 0;
        ag = ah;
        for (j = 0; j <= af; ++j, ++ag) {
            a = an.digits[ag] + ak.digits[j] * aj.digits[ah] + ai;
            an.digits[ag] = a & T;
            ai = a >>> I
        }
        an.digits[ah + af + 1] = ai
    }
    an.isNeg = ak.isNeg != aj.isNeg;
    return an
}
function k(a, aj) {
    var ai, ah, ag;
    result = new b();
    ai = V(a);
    ah = 0;
    for (var af = 0; af <= ai; ++af) {
        ag = result.digits[af] + a.digits[af] * aj + ah;
        result.digits[af] = ag & T;
        ah = ag >>> I
    }
    result.digits[1 + ai] = ah;
    return result
}
function v(ai, al, ag, ak, aj) {
    var a = Math.min(al + aj, ai.length);
    for (var ah = al, af = ak; ah < a; ++ah, ++af) {
        ag[af] = ai[ah]
    }
}
var p = new Array(0, 32768, 49152, 57344, 61440, 63488, 64512, 65024, 65280, 65408, 65472, 65504, 65520, 65528, 65532, 65534, 65535);

function t(af, al) {
    var ah = Math.floor(al / o);
    var a = new b();
    v(af.digits, 0, a.digits, ah, a.digits.length - ah);
    var ak = al % o;
    var ag = o - ak;
    for (var ai = a.digits.length - 1, aj = ai - 1; ai > 0; --ai, --aj) {
        a.digits[ai] = ((a.digits[ai] << ak) & T) | ((a.digits[aj] & p[ak]) >>> (ag))
    }
    a.digits[0] = ((a.digits[ai] << ak) & T);
    a.isNeg = af.isNeg;
    return a
}
var E = new Array(0, 1, 3, 7, 15, 31, 63, 127, 255, 511, 1023, 2047, 4095, 8191, 16383, 32767, 65535);

function l(af, al) {
    var ag = Math.floor(al / o);
    var a = new b();
    v(af.digits, ag, a.digits, 0, af.digits.length - ag);
    var aj = al % o;
    var ak = o - aj;
    for (var ah = 0, ai = ah + 1; ah < a.digits.length - 1; ++ah, ++ai) {
        a.digits[ah] = (a.digits[ah] >>> aj) | ((a.digits[ai] & E[aj]) << ak)
    }
    a.digits[a.digits.length - 1] >>>= aj;
    a.isNeg = af.isNeg;
    return a
}
function y(af, ag) {
    var a = new b();
    v(af.digits, 0, a.digits, ag, a.digits.length - ag);
    return a
}
function h(af, ag) {
    var a = new b();
    v(af.digits, ag, a.digits, 0, a.digits.length - ag);
    return a
}
function N(af, ag) {
    var a = new b();
    v(af.digits, 0, a.digits, 0, ag);
    return a
}
function f(a, ag) {
    if (a.isNeg != ag.isNeg) {
        return 1 - 2 * Number(a.isNeg)
    }
    for (var af = a.digits.length - 1; af >= 0; --af) {
        if (a.digits[af] != ag.digits[af]) {
            if (a.isNeg) {
                return 1 - 2 * Number(a.digits[af] > ag.digits[af])
            } else {
                return 1 - 2 * Number(a.digits[af] < ag.digits[af])
            }
        }
    }
    return 0
}
function w(aj, ai) {
    var a = H(aj);
    var ah = H(ai);
    var ag = ai.isNeg;
    var ao, an;
    if (a < ah) {
        if (aj.isNeg) {
            ao = P(c);
            ao.isNeg = !ai.isNeg;
            aj.isNeg = false;
            ai.isNeg = false;
            an = S(ai, aj);
            aj.isNeg = true;
            ai.isNeg = ag
        } else {
            ao = new b();
            an = P(aj)
        }
        return new Array(ao, an)
    }
    ao = new b();
    an = aj;
    var al = Math.ceil(ah / o) - 1;
    var ak = 0;
    while (ai.digits[al] < e) {
        ai = t(ai, 1);
        ++ak;
        ++ah;
        al = Math.ceil(ah / o) - 1
    }
    an = t(an, ak);
    a += ak;
    var ar = Math.ceil(a / o) - 1;
    var ax = y(ai, ar - al);
    while (f(an, ax) != -1) {
        ++ao.digits[ar - al];
        an = S(an, ax)
    }
    for (var av = ar; av > al; --av) {
        var am = (av >= an.digits.length) ? 0 : an.digits[av];
        var aw = (av - 1 >= an.digits.length) ? 0 : an.digits[av - 1];
        var au = (av - 2 >= an.digits.length) ? 0 : an.digits[av - 2];
        var at = (al >= ai.digits.length) ? 0 : ai.digits[al];
        var af = (al - 1 >= ai.digits.length) ? 0 : ai.digits[al - 1];
        if (am == at) {
            ao.digits[av - al - 1] = T
        } else {
            ao.digits[av - al - 1] = Math.floor((am * Q + aw) / at)
        }
        var aq = ao.digits[av - al - 1] * ((at * Q) + af);
        var ap = (am * M) + ((aw * Q) + au);
        while (aq > ap) {
            --ao.digits[av - al - 1];
            aq = ao.digits[av - al - 1] * ((at * Q) | af);
            ap = (am * Q * Q) + ((aw * Q) + au)
        }
        ax = y(ai, av - al - 1);
        an = S(an, k(ax, ao.digits[av - al - 1]));
        if (an.isNeg) {
            an = g(an, ax);
            --ao.digits[av - al - 1]
        }
    }
    an = l(an, ak);
    ao.isNeg = aj.isNeg != ag;
    if (aj.isNeg) {
        if (ag) {
            ao = g(ao, c)
        } else {
            ao = S(ao, c)
        }
        ai = l(ai, ak);
        an = S(ai, an)
    }
    if (an.digits[0] == 0 && V(an) == 0) {
        an.isNeg = false
    }
    return new Array(ao, an)
}
function Y(a, af) {
    return w(a, af)[0]
}
function z(a, af) {
    return w(a, af)[1]
}
function s(af, ag, a) {
    return z(ae(af, ag), a)
}
function G(ag, ai) {
    var af = c;
    var ah = ag;
    while (true) {
        if ((ai & 1) != 0) {
            af = ae(af, ah)
        }
        ai >>= 1;
        if (ai == 0) {
            break
        }
        ah = ae(ah, ah)
    }
    return af
}
function F(ah, ak, ag) {
    var af = c;
    var ai = ah;
    var aj = ak;
    while (true) {
        if ((aj.digits[0] & 1) != 0) {
            af = s(af, ai, ag)
        }
        aj = l(aj, 1);
        if (aj.digits[0] == 0 && V(aj) == 0) {
            break
        }
        ai = s(ai, ai, ag)
    }
    return af
}
var X = {
    setMaxDigits: u,
    biCopy: P,
    biHighIndex: V,
    BigInt: b,
    biDivide: Y,
    biDivideByRadixPower: h,
    biMultiply: ae,
    biModuloByRadixPower: N,
    biSubtract: S,
    biAdd: g,
    biCompare: f,
    biShiftRight: l,
    biFromHex: W,
    biToHex: B,
    biToString: O,
    biFromString: C
};
ab.BigTools = ab.BigTools || X

})(window);
(function(c) {
var h = c.BigTools,
a = h.BigInt,
e = h.biFromHex,
f = h.biHighIndex;

function d(k) {
    this.modulus = h.biCopy(k);
    this.k = f(this.modulus) + 1;
    var l = new a();
    l.digits[2 * this.k] = 1;
    this.mu = h.biDivide(l, this.modulus);
    this.bkplus1 = new a();
    this.bkplus1.digits[this.k + 1] = 1;
    this.modulo = function(u) {
        var t = h.biDivideByRadixPower(u, this.k - 1);
        var q = h.biMultiply(t, this.mu);
        var p = h.biDivideByRadixPower(q, this.k + 1);
        var o = h.biModuloByRadixPower(u, this.k + 1);
        var v = h.biMultiply(p, this.modulus);
        var n = h.biModuloByRadixPower(v, this.k + 1);
        var m = h.biSubtract(o, n);
        if (m.isNeg) {
            m = h.biAdd(m, this.bkplus1)
        }
        var s = h.biCompare(m, this.modulus) >= 0;
        while (s) {
            m = h.biSubtract(m, this.modulus);
            s = h.biCompare(m, this.modulus) >= 0
        }
        return m
    };
    this.multiplyMod = function(m, o) {
        var n = h.biMultiply(m, o);
        return this.modulo(n)
    };
    this.powMod = function(n, q) {
        var m = new a();
        m.digits[0] = 1;
        var o = n;
        var p = q;
        while (true) {
            if ((p.digits[0] & 1) != 0) {
                m = this.multiplyMod(m, o)
            }
            p = h.biShiftRight(p, 1);
            if (p.digits[0] == 0 && f(p) == 0) {
                break
            }
            o = this.multiplyMod(o, o)
        }
        return m
    }
}
function g(l, m, k) {
    this.e = e(l);
    this.d = e(m);
    this.m = e(k);
    this.chunkSize = 2 * f(this.m);
    this.radix = 16;
    this.barrett = new d(this.m)
}
function b(k) {
    return (k < 10 ? "0" : "") + String(k)
}
g.encryptedString = function(t, w) {
    var r = new Array();
    var l = w.length;
    var p = 0;
    while (p < l) {
        r[p] = w.charCodeAt(p);
        p++
    }
    while (r.length % t.chunkSize != 0) {
        r[p++] = 0
    }
    var q = r.length;
    var x = "";
    var o, n, m;
    for (p = 0; p < q; p += t.chunkSize) {
        m = new a();
        o = 0;
        for (n = p; n < p + t.chunkSize; ++o) {
            m.digits[o] = r[n++];
            m.digits[o] += r[n++] << 8
        }
        var v = t.barrett.powMod(m, t.e);
        var u = t.radix == 16 ? h.biToHex(v) : h.biToString(v, t.radix);
        x += u + " "
    }
    return x.substring(0, x.length - 1)
};
g.decryptedString = function(o, p) {
    var r = p.split(" ");
    var k = "";
    var n, m, q;
    for (n = 0; n < r.length; ++n) {
        var l;
        if (o.radix == 16) {
            l = e(r[n])
        } else {
            l = h.biFromString(r[n], o.radix)
        }
        q = o.barrett.powMod(l, o.d);
        for (m = 0; m <= f(q); ++m) {
            k += String.fromCharCode(q.digits[m] & 255, q.digits[m] >> 8)
        }
    }
    if (k.charCodeAt(k.length - 1) == 0) {
        k = k.substring(0, k.length - 1)
    }
    return k
};
c.RSAKeyPair = c.RSAKeyPair || g

})(window);

function getpass(b,d,p) {
var c = new RSAKeyPair(b, "", d);
a = RSAKeyPair.encryptedString(c, p);
return a;
}

解决方案

真逗,这么一段的目的是什么?

时间: 2024-10-24 00:51:30

请问这个 a怎么算出来,谢谢javascript的相关文章

android 请问如何改变drawableTop大小?谢谢。

问题描述 android 请问如何改变drawableTop大小?谢谢. 请问如何改变drawableTop大小?谢谢. 解决方案 建议使用一个ImageView+TextView来做,然后修改ImageView的大小即可. 解决方案二: 可以用textview的属性:android:drawablePadding=""""来控制 解决方案三: 安卓 貌似没提供此项接口.要么改图片大小,要么使用imageview

请高人指点下 pi 衰减器的计算反算代码.谢谢

问题描述 帮忙指点下pi衰减器的计算反算代码.谢谢知道R1,R2,R3的阻值,计算出这个衰减了多少db,匹配阻抗是多少Z0=Z1可以加多悬赏!图片如下连接

请问这个特效如何实现,谢谢帮助

问题描述 请大家帮忙,请问搜房网上那个搜索栏里"区县/地铁"下拉菜单的特效是怎么实现的.谢谢大家的帮助 解决方案 解决方案二:那个下拉框可以用个图片覆盖,点击下拉的时候让下面影藏的div显示出来就行了解决方案三:不就是个绝对定位的DIV么?position:absolute;z-index:100;display:block;left:419px;top:457px;解决方案四:引用2楼zell419的回复: 不就是个绝对定位的DIV么?position:absolute;z-inde

请问这种情况是否算regression

问题描述 1.0的时候是用firefox3测试的,2.0的时候是用firefox5测试的.结果2.0的版本在firefox5有问题.其实1.0版本在FF5上也是有同样的问题,只不过当年只有FF3.请问这种算regression吗?

asp改成jsp.请问怎么改.下面这段.谢谢

问题描述 Dimfso,f,f1,fc,sSetfso=CreateObject("Scripting.FileSystemObject")Setf=fso.GetFolder(Application("TransLogDirectory"))

为什么大家都有dategrid分页呢,在VS2005里没有这个控件,请问我如果用datalist应该怎样分页呢?谢谢!

问题描述 为什么大家都有dategrid分页呢,在VS2005里没有这个控件,请问我如果用datalist应该怎样分页呢?谢谢!我是刚学asp.net的,我用的是vs2005版本的,我想用datalist分页,请问应该怎样分页了.谢谢大家了! 解决方案 解决方案二:datagrid的设置里边有自动分页功能,datalist没有自动分页功能,要通过代码来实现datalist的分页解决方案三:你可以使用AspNetPager免费分页控件来为DataList分页,AspNetPager下载及演示地址为

Javascript中this关键字详解

Quiz 请看下面的代码,最后alert出来的是什么呢? 1 var name = "Bob"; 2 var nameObj ={ 3 name : "Tom", 4 showName : function(){ 5 alert(this.name); 6 }, 7 waitShowName : function(){ 8 setTimeout(this.showName, 1000); 9 } 10 }; 11 12 nameObj.waitShowName();

JavaScript正则表达式大全

字符 含意 \ 做为转意,即通常在"\"后面的字符不按原来意义解释,如/b/匹配字符"b",当b前面加了反斜杆后/\b/,转意为匹配一个单词的边界.  -或-  对正则表达式功能字符的还原,如"*"匹配它前面元字符0次或多次,/a*/将匹配a,aa,aaa,加了"\"后,/a\*/将只匹配"a*". ^ 匹配一个输入或一行的开头,/^a/匹配"an A",而不匹配"An a&q

请问使用MyEclips6编辑JSP时使用alt+/弹出提示时报错的问题!

问题描述 以前在编辑JSP中的java时使用alt+/是可以有提示出现的(语法补充),但是不知为何现在每次使用,在Eclips的左下方都会报:"Content Assist not available at the current location"红色警告,并且无法出现语法补充的下拉框了,我也重新修改过Key设置,但是一直没搞定(在编辑java文件的时候alt+/是可以正常使用的),有没有朋友遇到过类似的问题,想请问一下要如何解决?谢谢!!问题补充: alt+/只关联了Content