tx · 5eaQfpkwGf4MuAfpwDjC7qH5yYPh67GFyzmSrusHmDuM 3N272hFk6FBTgLM5HqpYVcCVmMcSCrEma9T: -0.01000000 Waves 2023.06.22 20:36 [2634154] smart account 3N272hFk6FBTgLM5HqpYVcCVmMcSCrEma9T > SELF 0.00000000 Waves
{ "type": 13, "id": "5eaQfpkwGf4MuAfpwDjC7qH5yYPh67GFyzmSrusHmDuM", "fee": 1000000, "feeAssetId": null, "timestamp": 1687455465879, "version": 2, "chainId": 84, "sender": "3N272hFk6FBTgLM5HqpYVcCVmMcSCrEma9T", "senderPublicKey": "97sWz4UZWijkagGprhucQHR7b7nN6FfojMELnzuFEyY1", "proofs": [ "3H78hU9swACBEDSH7YQbtyqaQbqU7u3YENnx5MjmN7o6QxkMgfWkQy88ykQpGZAVHBPonirLnmWvNJjRPC6XtKbT" ], "script": "base64:AAIFAAAAAAAAAAcIAhIDCgEYAAAABAAAAAAJY29sb3JMaXN0CQAETAAAAAICAAAABGFxdWEJAARMAAAAAgIAAAAFYmxhY2sJAARMAAAAAgIAAAAEYmx1ZQkABEwAAAACAgAAAAdmdWNoc2lhCQAETAAAAAICAAAABGdyYXkJAARMAAAAAgIAAAAFZ3JlZW4JAARMAAAAAgIAAAAEbGltZQkABEwAAAACAgAAAAZtYXJvb24JAARMAAAAAgIAAAAEbmF2eQkABEwAAAACAgAAAAVvbGl2ZQkABEwAAAACAgAAAAZwdXJwbGUJAARMAAAAAgIAAAADcmVkCQAETAAAAAICAAAABnNpbHZlcgkABEwAAAACAgAAAAR0ZWFsCQAETAAAAAICAAAABXdoaXRlCQAETAAAAAICAAAABnllbGxvdwUAAAADbmlsAQAAAAttYXBJbnRUb1N1bQAAAAIAAAAFYWNjdW0AAAAEbmV4dAkAASwAAAACBQAAAAVhY2N1bQUAAAAEbmV4dAEAAAAPcGl4ZWxWYWxpZGF0aW9yAAAAAgAAAAVhY2N1bQAAAARuZXh0BAAAAAVhcnJheQkABLUAAAACBQAAAARuZXh0AgAAA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AAAAAAFAAAAAAAAAAAFQAAAAAAAAAAFgAAAAAAAAAAFwAAAAAAAAAAGAAAAAAAAAAAGQAAAAAAAAAAGgAAAAAAAAAAGwAAAAAAAAAAHAAAAAAAAAAAHQAAAAAAAAAAHgAAAAAAAAAAHwAAAAAAAAAAIAAAAAAAAAAAIQAAAAAAAAAAIgAAAAAAAAAAIwAAAAAAAAAAJAAAAAAAAAAAJQAAAAAAAAAAJgAAAAAAAAAAJwAAAAAAAAAAKAAAAAAAAAAAKQAAAAAAAAAAKgAAAAAAAAAAKwAAAAAAAAAALAAAAAAAAAAALQAAAAAAAAAALgAAAAAAAAAALwAAAAAAAAAAMAAAAAAAAAAAMQAAAAAAAAAAMgAAAADOFyVB", "height": 2634154, "applicationStatus": "succeeded", "spentComplexity": 0 } View: original | compacted Prev: CxTbrkd2oNUH2ko6LurrsKn49E5MVA31EnpiR1oAsp59 Next: 57vzjyzqj5mY7uZJv8eDNHfCVp1uu4teGZLe3yx9WfXq Diff:
Old | New | Differences | |
---|---|---|---|
8 | 8 | ||
9 | 9 | func pixelValidatior (accum,next) = { | |
10 | 10 | let array = split(next, "-") | |
11 | - | if (!(accum)) | |
11 | + | if (if (if (if (accum) | |
12 | + | then containsElement(colorList, array[0]) | |
13 | + | else false) | |
14 | + | then (100 > parseIntValue(array[1])) | |
15 | + | else false) | |
16 | + | then (100 > parseIntValue(array[2])) | |
17 | + | else false) | |
12 | 18 | then true | |
13 | 19 | else false | |
14 | 20 | } |
Old | New | Differences | |
---|---|---|---|
1 | 1 | {-# STDLIB_VERSION 5 #-} | |
2 | 2 | {-# SCRIPT_TYPE ACCOUNT #-} | |
3 | 3 | {-# CONTENT_TYPE DAPP #-} | |
4 | 4 | let colorList = ["aqua", "black", "blue", "fuchsia", "gray", "green", "lime", "maroon", "navy", "olive", "purple", "red", "silver", "teal", "white", "yellow"] | |
5 | 5 | ||
6 | 6 | func mapIntToSum (accum,next) = (accum + next) | |
7 | 7 | ||
8 | 8 | ||
9 | 9 | func pixelValidatior (accum,next) = { | |
10 | 10 | let array = split(next, "-") | |
11 | - | if (!(accum)) | |
11 | + | if (if (if (if (accum) | |
12 | + | then containsElement(colorList, array[0]) | |
13 | + | else false) | |
14 | + | then (100 > parseIntValue(array[1])) | |
15 | + | else false) | |
16 | + | then (100 > parseIntValue(array[2])) | |
17 | + | else false) | |
12 | 18 | then true | |
13 | 19 | else false | |
14 | 20 | } | |
15 | 21 | ||
16 | 22 | ||
17 | 23 | func paintOver (accum,next) = { | |
18 | 24 | let array = split(next, "-") | |
19 | 25 | (accum ++ [StringEntry(((array[1] + "-") + array[2]), array[0])]) | |
20 | 26 | } | |
21 | 27 | ||
22 | 28 | ||
23 | 29 | @Callable(i) | |
24 | 30 | func draw (pixels) = { | |
25 | 31 | let textPixelsList = ["red-17-67", "blue-18-67", "red-19-67", "green-20-67"] | |
26 | 32 | let isValid = { | |
27 | 33 | let $l = textPixelsList | |
28 | 34 | let $s = size($l) | |
29 | 35 | let $acc0 = true | |
30 | 36 | func $f0_1 ($a,$i) = if (($i >= $s)) | |
31 | 37 | then $a | |
32 | 38 | else pixelValidatior($a, $l[$i]) | |
33 | 39 | ||
34 | 40 | func $f0_2 ($a,$i) = if (($i >= $s)) | |
35 | 41 | then $a | |
36 | 42 | else throw("List size exceeds 10") | |
37 | 43 | ||
38 | 44 | $f0_2($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($acc0, 0), 1), 2), 3), 4), 5), 6), 7), 8), 9), 10) | |
39 | 45 | } | |
40 | 46 | if (!(isValid)) | |
41 | 47 | then throw("Is't walid") | |
42 | 48 | else { | |
43 | 49 | let $l = textPixelsList | |
44 | 50 | let $s = size($l) | |
45 | 51 | let $acc0 = nil | |
46 | 52 | func $f1_1 ($a,$i) = if (($i >= $s)) | |
47 | 53 | then $a | |
48 | 54 | else paintOver($a, $l[$i]) | |
49 | 55 | ||
50 | 56 | func $f1_2 ($a,$i) = if (($i >= $s)) | |
51 | 57 | then $a | |
52 | 58 | else throw("List size exceeds 50") | |
53 | 59 | ||
54 | 60 | $f1_2($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($acc0, 0), 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), 29), 30), 31), 32), 33), 34), 35), 36), 37), 38), 39), 40), 41), 42), 43), 44), 45), 46), 47), 48), 49), 50) | |
55 | 61 | } | |
56 | 62 | } | |
57 | 63 | ||
58 | 64 |
github/deemru/w8io/026f985 30.22 ms ◑