Hi Aaron, thank you for the reply:
actually yes, I have followed this formula that I found in the pancacke router contract.
but my problem is the correct way to calculate these values:
amountTokenA and amountTokenB

suppose I want to add 0.1 BNB in the liquidity pool BNB/CAKE
how is the correct way to calculate amountTokenA and amountTokenB ?

Mar 29, 2022, 4:45 PM
0.1 BNB would be the amount of one token (WBNB), and the other amount is just the proportially correct amount of the other token (matching the current ratio of the reserves)
Mar 29, 2022, 4:51 PM
ok thank you very much
Mar 29, 2022, 5:35 PM

© 2024 Draquery.com All rights reserved.