-- Open Analytics (OA) bounties are bounties without specific prompts, just a direction and a reward.
-- It’s your chance to have your brain follow your heart — got a spark of interest, or a loose thread, or a weirdly-specific question gnawing at the back of your mind? Follow it as far as you can!
-- Pay by Quality
-- Your score determines your final payout.
-- Grand Prize
-- 150 USDC (A score of 11 or 12 earns you a Grand Prize title)
-- Payout
-- 100 USDC
-- Score Multiplier
-- 0-7 : 0%
-- 8 : 50%
-- 9 : 75%
-- 10 : 100%
-- 11 : 125%
-- 12 : 150%
-- Payout Network Ethereum
-- Level Intermediate
-- Difficulty Hard
with borrowers as (
select
borrower,
count(distinct tx_hash) as loan_frequency,
rank() over (order by loan_frequency,borrower desc) as rank
from ethereum.maker.ez_flash_loans
where block_timestamp >= '{{start_date}}'
and symbol is not null
and borrower <> '0x0000000000000000000000000000000000000000'
group by borrower
)
select
count(distinct borrower) as n_wallets,
CASE
WHEN loan_frequency > 0 and loan_frequency <= 1 THEN 'a.0-1'
WHEN loan_frequency > 1 and loan_frequency <= 10 THEN 'b.1-10'