aqua-playground/aqua/examples/foldJoin.aqua

18 lines
409 B
Plaintext
Raw Normal View History

import "@fluencelabs/aqua-lib/builtin.aqua"
service Op2("op"):
identity(s: u64)
func getTwoResults(relay: string) -> []u64:
on relay:
k <- Op.string_to_b58(%init_peer_id%)
nodes <- Kademlia.neighborhood(k, false)
res: *u64
for n <- nodes par:
on n:
try:
res <- Peer.timestamp_sec()
Op2.identity(res!)
Op2.identity(res!1)
Op2.identity(res!2)
<- res