tx · 47fQxWfxcvz3FfiTjtKH7HBUSyBRp4xoEW8dXaDjLjBB

3N4revPn12feiSAyC78tAZEJfsyprVYPzsL:  -0.05000000 Waves

2022.02.18 10:03 [1928736] smart account 3N4revPn12feiSAyC78tAZEJfsyprVYPzsL > SELF 0.00000000 Waves

{ "type": 13, "id": "47fQxWfxcvz3FfiTjtKH7HBUSyBRp4xoEW8dXaDjLjBB", "fee": 5000000, "feeAssetId": null, "timestamp": 1645167845490, "version": 2, "chainId": 84, "sender": "3N4revPn12feiSAyC78tAZEJfsyprVYPzsL", "senderPublicKey": "5smGxL7bfeRokaN53Z31Y72dF2Lkr5Cg1kuWRV3gniNe", "proofs": [ "5d9wZzf9he3GCMYSxwQDJ38H1ixpSUrvrEyLVRQCUWXSwcHJvirEMQARGfEcv9TzFk6V8XK4TznzPXQF5ZG2iTzd" ], "script": "base64:AAIFAAAAAAAAABgIAhIECgIBARIECgIBARIICgYBAQEIAQEAAAAZAAAAAAtzdHJBc3NldElkQQIAAAAsMzROOVljRUVUTFduOTNxWVE2NEVzUDF4ODl0U3J1SlU0NFJyRU1TWFhFUEoAAAAAC3N0ckFzc2V0SWRCAgAAACxERzJ4RmtQZER3S1VvQmt6R0FoUXRMcFNHemZYTGlDWVBFemVLSDJBZDI0cAAAAAAIYXNzZXRJZEEDCQAAAAAAAAIFAAAAC3N0ckFzc2V0SWRBAgAAAAVXQVZFUwUAAAAEdW5pdAkAAlkAAAABBQAAAAtzdHJBc3NldElkQQAAAAAIYXNzZXRJZEIDCQAAAAAAAAIFAAAAC3N0ckFzc2V0SWRCAgAAAAVXQVZFUwUAAAAEdW5pdAkAAlkAAAABBQAAAAtzdHJBc3NldElkQgAAAAADZmVlAAAAAAAAAAH0AAAAAA1mZWVHb3Zlcm5hbmNlAAAAAAAAAADIAAAAAAlmZWVTY2FsZTYAAAAAAAAPQkAAAAAABnNjYWxlMwAAAAAAAAAD6AAAAAAGc2NhbGU4AAAAAAAF9eEAAAAAAAdzY2FsZTEy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kAAZEAAAACCAUAAAACdHgAAAAGcHJvb2ZzAAAAAAAAAAAACAUAAAACdHgAAAAPc2VuZGVyUHVibGljS2V5rY9OCA==", "height": 1928736, "applicationStatus": "succeeded", "spentComplexity": 0 } View: original | compacted Prev: HnXK7yM16Rk9BRHepsw8RZFJsssHZR16YJs8jyvDxxxP Next: J5b4bNh5jk7ZntukHhZyMEX3rug9fYDwyucLH2Lqhy8p Diff:
OldNewDifferences
136136 let D = pow(fraction(toBigInt(w), toBigInt(x), toBigInt(i)), 0, toBigInt(5), 1, (l / 2), DOWN)
137137 let E = pow(toBigInt((A - u)), m, toBigInt(r), s, m, DOWN)
138138 let ah = toInt(fraction(B, toBigInt(j), C))
139- let ai = toInt(fraction(D, E, toBigInt(j)))
140- let Q = (ah + (2 * ai))
139+ let ai = (2 * toInt(fraction(D, E, toBigInt(j))))
140+ let Q = (ah + ai)
141141 [IntegerEntry("invariant", Q)]
142142 }
143143
Full:
OldNewDifferences
11 {-# STDLIB_VERSION 5 #-}
22 {-# SCRIPT_TYPE ACCOUNT #-}
33 {-# CONTENT_TYPE DAPP #-}
44 let a = "34N9YcEETLWn93qYQ64EsP1x89tSruJU44RrEMSXXEPJ"
55
66 let b = "DG2xFkPdDwKUoBkzGAhQtLpSGzfXLiCYPEzeKH2Ad24p"
77
88 let c = if ((a == "WAVES"))
99 then unit
1010 else fromBase58String(a)
1111
1212 let d = if ((b == "WAVES"))
1313 then unit
1414 else fromBase58String(b)
1515
1616 let e = 500
1717
1818 let f = 200
1919
2020 let g = 1000000
2121
2222 let h = 1000
2323
2424 let i = 100000000
2525
2626 let j = 1000000000000
2727
2828 let k = 1000
2929
3030 let l = 8
3131
3232 let m = 12
3333
3434 let n = 50
3535
3636 let o = 100
3737
3838 let p = 90000000
3939
4040 let q = 110000000
4141
4242 let r = 50
4343
4444 let s = 2
4545
4646 let t = 46000000
4747
4848 let u = 460000000000
4949
5050 func v (w,x) = (((fraction(j, w, x) + fraction(j, x, w)) / 2) / 10000)
5151
5252
5353 func y (w,x) = ((fraction(j, w, x) + fraction(j, x, w)) / 2)
5454
5555
5656 func z (w,x) = {
5757 let A = v(w, x)
5858 let B = (w + x)
5959 let C = pow(A, l, r, s, l, CEILING)
6060 let D = pow(fraction(w, x, i), 0, 5, 1, (l / 2), DOWN)
6161 let E = pow((A - t), l, r, s, l, DOWN)
6262 let F = fraction(B, i, C)
6363 let G = (2 * fraction(D, E, i))
6464 (F + G)
6565 }
6666
6767
6868 func H (I,J,K,L,M,N) = {
6969 let O = (i - ((i * 1) / 10000000))
7070 let P = (K - L)
7171 let w = (I + M)
7272 let x = (J + M)
7373 let Q = z(I, J)
7474 let R = if ((N == a))
7575 then z(w, (J - K))
7676 else if ((N == b))
7777 then z((I - K), x)
7878 else throw("Wrong asset in payment")
7979 let S = fraction(i, Q, R)
8080 func T (U,V) = if ((U == -1))
8181 then {
8282 let W = (K - ((V * P) / 5))
8383 let X = if ((N == a))
8484 then z(w, (J - W))
8585 else z((I - W), x)
8686 if ((X > Q))
8787 then W
8888 else -1
8989 }
9090 else U
9191
9292 let Y = {
9393 let Z = [1, 2, 3, 4, 5]
9494 let aa = size(Z)
9595 let ab = -1
9696 func ac (ad,ae) = if ((ae >= aa))
9797 then ad
9898 else T(ad, Z[ae])
9999
100100 func af (ad,ae) = if ((ae >= aa))
101101 then ad
102102 else throw("List size exceeds 5")
103103
104104 af(ac(ac(ac(ac(ac(ab, 0), 1), 2), 3), 4), 5)
105105 }
106106 if ((0 > Y))
107107 then throw("something went wrong while working with amountToSend")
108108 else if (if ((S > O))
109109 then (R > Q)
110110 else false)
111111 then K
112112 else Y
113113 }
114114
115115
116116 @Callable(ag)
117117 func invariantCalcc (w,x) = {
118118 let A = v(w, x)
119119 let B = (w + x)
120120 let C = pow(A, l, r, s, l, CEILING)
121121 let D = pow(fraction(w, x, i), 0, 5, 1, (l / 2), DOWN)
122122 let E = pow((A - t), l, r, s, l, DOWN)
123123 let ah = fraction(B, i, C)
124124 let ai = fraction(D, E, i)
125125 let Q = (ah + (2 * ai))
126126 [IntegerEntry("invariant", Q)]
127127 }
128128
129129
130130
131131 @Callable(ag)
132132 func invariantCalccBigInt (w,x) = {
133133 let A = y(w, x)
134134 let B = toBigInt((w + x))
135135 let C = pow(toBigInt(A), m, toBigInt(r), s, m, CEILING)
136136 let D = pow(fraction(toBigInt(w), toBigInt(x), toBigInt(i)), 0, toBigInt(5), 1, (l / 2), DOWN)
137137 let E = pow(toBigInt((A - u)), m, toBigInt(r), s, m, DOWN)
138138 let ah = toInt(fraction(B, toBigInt(j), C))
139- let ai = toInt(fraction(D, E, toBigInt(j)))
140- let Q = (ah + (2 * ai))
139+ let ai = (2 * toInt(fraction(D, E, toBigInt(j))))
140+ let Q = (ah + ai)
141141 [IntegerEntry("invariant", Q)]
142142 }
143143
144144
145145
146146 @Callable(ag)
147147 func exchange (I,J,aj,ak,al,am) = {
148148 let an = H(I, J, al, am, aj, ak)
149149 let ao = fraction(an, f, g)
150150 let ap = fraction(an, (g - e), g)
151151 ([IntegerEntry("sendAmount", an), IntegerEntry("sendAmountWithComission", ap), IntegerEntry("invariant", z(I, J))] ++ (if ((ak == a))
152152 then [IntegerEntry("invariantNew", z((I + aj), (J - an)))]
153153 else [IntegerEntry("invariantNew", z((I - an), (J + aj)))]))
154154 }
155155
156156
157157 @Verifier(aq)
158158 func ar () = sigVerify(aq.bodyBytes, aq.proofs[0], aq.senderPublicKey)
159159

github/deemru/w8io/169f3d6 
28.95 ms