11

The answer is that uniswap is a set of Smart Contract running on the Ethereum platform and thus requires gas in order to execute any functions. Meaning that when you swap token A for token B or token C it is more or less the same function that is being called in order to perform the necessary logic of matching buyers and sellers. This is only an issue (such ...


10

I believe you're searching for logic in a place where it does not exist. Burning tokens before token "launch" is actually a shitcoin trend which makes zero sense and in general something doesn't have to make sense if everyone does it. Burning tokens which are not backed up by any kind of liquidity is useless. Shitcoins cannot offer much in the way ...


7

It's an effective form of marketing. From a mathematical point of view burning tokens on deployment is the same as never creating those tokens at all, but from a marketing perspective: It creates the headline of "We burned x% of tokens" with the implied, but not actually true implication: smaller supply -> higher price It makes the "...


6

How does uniswap creator take profit? Uniswap itself made $11 million in their Series A funding round. (See here.) I believe they currently use this as their source of funds for operating and development. However, the Uniswap contracts - at least in v2, I'm assuming also for v3 - do have a mechanism to take a fee from each trade. In the Whitepaper, section ...


5

LP Token is just one name for the tokens you get, when you provide liquidity to a pool/pair, they may have other names, depending on where you read about them. Uniswap tokens are something different, they allow you to vote on some things related to the future of Uniswap. They are listed at Coinmarketcap (currently #8) and may be traded at some Exchanges. The ...


3

Well, after some research I can answer my question. I was indeed right, treasury fee is 1/6 (16.6%) of the total fee. Precisely, the code for this formula is in the core repository: code unction _mintFee(uint112 _reserve0, uint112 _reserve1) private returns (bool feeOn) { address feeTo = IShuttleFactory(factory).feeTo(); feeOn = feeTo != ...


3

As you mentioned it seems they have a particular way of doing things, and I am not too familiar with Mdex, but I have worked with Uniswap's sub-graph implementation. This isn't necessarily a solution to your question but may help you get there. After looking into https://info.mdex.com I spotted that they use a similar approach to Uniswap's sub-graph. They ...


3

A DEX essentially allows you to swap tokens and create liquidity pools, which means that you don't create (mint) new tokens in general. Only if the DEX has the possibility of staking, then you may create LP tokens (Liquidity Pool tokens) and send them to the stakers in exchange of their standard tokens. If the contract is verified in etherscan.io, you can ...


3

You'll first need the address of the contract for the pair whose price(s) you want to access. Two ways to do this: Find the addresses of the two tokens separately, and feed them into the UniswapV2Factory contract to get the address of the pair's contract; or... Go to Uniswap, enter the two tokens into the usual interface, then visit the "View Pair ...


3

Whoever provides the liquidity has the option to take his share of the liquidity out of the pool, at any time they want. Liquidity is never "sold off" as such, since Uniswap price is based on a bonding price curve. So the trading price simply changes between trades, reflecting which asset of the pair is bought more and which sold. There is also no &...


2

It is easy to create an NFT that transfers a fixed fee to you at every transfer of this NFT. Just add transfer (of ETH, or an ERC-20/1155) to it. It is nearly impossible to get a transaction percentage every time a token is traded: Suppose somebody buys your token on Uniswap. Then your token receives from a Uniswap a message to be transferred. The token can ...


2

As explained in the r/1inch post here, in my example from Step 5 above, as the staked liquidity approaches $1.5B, the APY would decrease due to the increased supply, assuming the trade volume remains constant. Rewards for Top 10 Liquidity Pools Looking at the current Top 10 liquidity pools (LPs) in terms of liquidity volume, the total liquidity is $2B, with ...


2

I think this question will be closed as off-topic as it's a question about Cardano. (Please ask on a Cardano forum.) Just to clear one thing up: Why doesn't Uniswap (a decentralized exchange) list anything Cardano-related? Uniswap is a smart contract on the Ethereum blockchain. It has no knowledge that Cardano exists. (See the first question in their FAQ: ...


2

Uniswap protocol is developed in Solidity, and you can find two main building blocks: uniswap-v2-core: Core smart contracts, essentially with the Factory, Pair and ERC20, together with a number of interfaces and libraries. uniswap-v2-periphery: additional smart contracts to interact with the Core ones. They simplify the process of doing swaps or adding/...


2

Uniswap only lists tokens created on Ethereum such as ERC-20 tokens. Polkadot is not an ERC20 token. It runs on its own blockchain. :)


2

There are three fees that apply when you make a trade on Uniswap. I don't know which fee you are referring to so I will break them all down. Gas fee. This is the fee that you pay so that miners will include your transaction in a block. The gas fees have been very high lately simply because a lot of people are using Ethereum blockchain and there is only a ...


2

Pancake Swap uses the same formula as Uniswap, but they have a 0.2% fee instead of 0.3% fee, which affects the calculation.


2

I've notived at least 2 different ways of doing it. Binance will send and keep a small Eth balance in the deposit address. They will use that Eth to send the tokens from the deposit wallet to the exchange hot wallet. Kraken uses contracts as deposits accounts instead of EOA. There is no Eth balance in those deposit contracts. Edit: The hot wallet calls a ...


2

Prices are set by the market. The best practice is to set the price to its fair value on the market. If there is no market yet, you have to evaluate it. This is basically what investment banks will do before a stock IPO. It's very hard to do and their army of finance professionals often screw up anyways. All in all, it is not an Ethereum question, but an ...


1

amount_in=14067900000000 amount_out=393017164305296368 reserve0=95594454080845 reserve1=3070347989941780637 amount_in_with_fee=amount_in*998-14067900000000*0.5 numerator=amount_in_with_fee*reserve1 denominator=reserve0*1000+amount_in_with_fee amount_out=round(numerator/denominator) = 393,017,164,305,296,368 I figured out the how, but not the why. I will ...


1

The product k would actually be constant, if the swap fee was 0%. Since AMMs usually have a fee, the product of the reserves is not really a constant in practice. The name ‘constant product market’ comes from the fact that, when the fee is zero (i.e., γ = 1), any trade ∆β to ∆α must change the reserves in such a way that the product RαRβ remains equal to ...


1

What's the reason all tokens have decimals? They don't have to use decimals. According to the ERC-20 standard description for decimals: "OPTIONAL - This method can be used to improve usability, but interfaces and other contracts MUST NOT expect these values to be present." For ERC-721: "...we find it contrived to require all ERC-721 ...


1

Each contract can have it's own "dead" or "burn" address. Saturna uses "0x000000000000000000000000000000000000dead" address for that, accounting for 33% of the total supply, according to BSCScan [1]: 0x000000000000000000000000000000000000dead => 333,964,566,341,675.193475472 On your calculation, keep in mind the "...


1

That's a lot of questions and to get you started, Uniswap is an example of what's possible. There is no reason why philanthropy would not be able to sustainably fund something like Uniswap. All Uniswap smart contract are open source. Most stocks are fungible: 1 share of a company is indistinguishable from 1 share of the same company. The stock in Uniswap ...


1

Dev Address - Some percentage of cake minted is sent to the dev address. For every 100 cake, 10 is sent to dev address. The dev address will then burn it. Update pool fn - Straight forward, it is used to update the number of cake to be emitted/allocated for each pool. Updating the staking pool - Changing LP token details. Reward debt - Whatever the user ...


1

The values for token0 and token1 are provided by the factory contract at the time of contract deployment. AFAIK, there is a separate contract for Each Pair of tokens deployed by using the Factory pattern and hence they don't need to configured/supplied by users.


1

A minimal example showing how to integrate 1inch in your smart contract using Brownie https://github.com/smye/1inch-swap this may help you


1

However, in DEXs like uniswap, it only says that it charges a 0.30% fee that goes to the liquidity providers. You are mixing too separate concepts Gas fee goes to Ethereum transaction miners for including your transaction in a block in Ethereum blockchain Uniswap fee goes to the liquidity providers of Uniswap pair You pay both when you swap at Uniswap or ...


1

To clarify a little bit -- Uniswap (the app) has an associated governance token, UNI. This token is used to vote on proposals, among other things. LP (liquidity provider) tokens are different than UNI. These LP tokens are created when you add liquidity to the Uniswap protocol. See above description. Uniswap pools require you to deposit two assets. If you ...


1

Depends on the exchange, but I doubt a trade is a new contract in any dex (decentralized exchange). A trade is typically a call to a certain function in a contract. That function executes the trade by calling some background contract functionality to calculate ratios and so on. If you wish to trade token A for token B, the trade looks typically something ...


Only top voted, non community-wiki answers of a minimum length are eligible