If there are 10000000abc coin and a for sure some would have deposit 1000abc some would have 10abc ...
so when ever i get stake how will i decide how much balance i have to put in all those accounts who deposit in the pool , how will i know the % of abc coin holder ,
Thank you anyone who help me out
I would say you would run a while/wend statement on all users balances and get the percentage of their balance compared to the total balance. Then, you would just distribute the staking rewards based off of that percentage. For example. If the total balance is 1,000 coins and a user has 100 coins, his percentage is 10%. So if the staking rewards were 10 coins, that user gets 1 coin. Hope this helps.