# pDAI to GIMME FIVE

The cost of 1 [GIMME FIVE](https://affection.gitbook.io/docs/token-contracts/gimme-five-5) is 5 [pDAI](https://affection.gitbook.io/docs/token-contracts/pdai-dai), to get this price you have to call a function on the [GIMME FIVE](https://affection.gitbook.io/docs/token-contracts/gimme-five-5) contract.

We can look at the verified contract code to see the prices: [View the contract code](https://scan.mypinata.cloud/ipfs/bafybeidn64pd2u525lmoipjl4nh3ooa2imd7huionjsdepdsphl5slfowy/#/token/0x2fc636E7fDF9f3E8d61033103052079781a6e7D2?tab=contract).

This guide assumes you’ve read and understand [how to interact with contracts](https://affection.gitbook.io/docs/contract-gui).

{% hint style="danger" %}
Buying only works with [pDAI](https://affection.gitbook.io/docs/token-contracts/pdai-dai) because [pUSDC](https://affection.gitbook.io/docs/token-contracts/pusdc-usdc) and [pUSDT](https://affection.gitbook.io/docs/token-contracts/pusdt-usdt) are bugged!
{% endhint %}

{% hint style="info" %}
Check the current [exchange rates](https://affection.gitbook.io/docs/faq#what-are-the-current-prices) to know which route is profitable!
{% endhint %}

## Step-by-step Guide

1. Add [pDAI](https://affection.gitbook.io/docs/token-contracts/pdai-dai) to [scgui.aff.icu](https://scgui.aff.icu)<br>

   <figure><img src="https://724266576-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FvpQTLAHrVaPSs8HZzOYQ%2Fuploads%2Fcox78tHr0WBLr4f0ZHsE%2Fimage.png?alt=media&#x26;token=ed1004c6-229f-4cbb-a0df-3794edcdae69" alt=""><figcaption></figcaption></figure>

2. Add [GIMME FIVE](https://affection.gitbook.io/docs/token-contracts/gimme-five-5) to scgui.aff.icu<br>

   <figure><img src="https://724266576-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FvpQTLAHrVaPSs8HZzOYQ%2Fuploads%2FSm7ZxP6ryLovaR7WlDjU%2Fimage.png?alt=media&#x26;token=96d87a37-d3a2-4a2f-8054-0b4b4e8b4dff" alt=""><figcaption></figcaption></figure>

3. Open the [pDAI](https://affection.gitbook.io/docs/token-contracts/pdai-dai) contract and call approve() with spender [GIMME FIVE](https://affection.gitbook.io/docs/token-contracts/gimme-five-5) and amount 5000000000000000000

   <figure><img src="https://724266576-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FvpQTLAHrVaPSs8HZzOYQ%2Fuploads%2Fu8vK5QqaHbKCEfyi0asR%2Fimage.png?alt=media&#x26;token=ed80b5f8-5d49-4309-8846-c4350474324d" alt=""><figcaption></figcaption></figure>

4. Open the [GIMME FIVE](https://affection.gitbook.io/docs/token-contracts/gimme-five-5) contract and call BuyWithDAI() to mint 1 token, this is sent straight to your wallet

   <figure><img src="https://724266576-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FvpQTLAHrVaPSs8HZzOYQ%2Fuploads%2FkOnU8KUn7VNUQxS4ihgh%2Fimage.png?alt=media&#x26;token=04c5b936-a2c8-4628-ac41-1a72186cce36" alt=""><figcaption></figcaption></figure>

5. Swap the [GIMME FIVE](https://affection.gitbook.io/docs/token-contracts/gimme-five-5) on PulseX for PLS or [pDAI](https://affection.gitbook.io/docs/token-contracts/pdai-dai)

Repeat steps 3-5 as long as there is a decent profit margin. Once you are comfortable you can approve a higher amount of tokens to skip step 3 and speed up your arbs!

## Optimizations

Use my [multi mint contracts](https://affection.gitbook.io/docs/multi-mint-contracts) to do this even faster! Instead of calling BuyWithDAI() once per transaction you can now loop it up to 1000-2000 times in a single transaction!

6. Open the [pDAI](https://affection.gitbook.io/docs/token-contracts/pdai-dai) contract on [scgui.aff.icu](https://scgui.aff.icu) and call approve() with spender [0xa4c61D20945c11855E7A390153fd29ceC9C7349b](https://affection.gitbook.io/docs/multi-mint-contracts/multi-g5) and any amount followed by 18 zeros, example: 500000000000000000000 for 500 tokens<br>

   <figure><img src="https://724266576-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FvpQTLAHrVaPSs8HZzOYQ%2Fuploads%2FdrlySkvmkBjanvMUua2R%2Fimage.png?alt=media&#x26;token=085418a2-32ee-48af-bb09-c3652c1efbfe" alt=""><figcaption></figcaption></figure>

7. Add the [Multi G5](https://affection.gitbook.io/docs/multi-mint-contracts/multi-g5) contract to [scgui.aff.icu](https://scgui.aff.icu)

   <figure><img src="https://724266576-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FvpQTLAHrVaPSs8HZzOYQ%2Fuploads%2FR2lYl0ELtMF62ysW5YME%2Fimage.png?alt=media&#x26;token=4b34f750-2b48-4424-ba42-65c361644eae" alt=""><figcaption></figcaption></figure>

8. Open it and call the function multiBuyWithDAI() with iterations 100, this will purchase 100 [GIMME FIVE](https://affection.gitbook.io/docs/token-contracts/gimme-five-5) from the contract in one transaction\ <br>

   <figure><img src="https://724266576-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FvpQTLAHrVaPSs8HZzOYQ%2Fuploads%2FWxCik0i3e9OCiBgB8lAf%2Fimage.png?alt=media&#x26;token=a0c4bae3-6877-40bc-83cd-35fd6f5c33a5" alt=""><figcaption></figcaption></figure>

{% hint style="info" %}
This should help reduce the gas costs to mint each token down to 5-10 PLS
{% endhint %}
