How to create a smart contract that can be bought, but cant be sold

I am working on a practical, and i need help with it.
i want to create a smart contract that can only be bought, but when try to sell, it will bring out warning that gas fee cant be estimated, even after the slippage is being increased..

i need help with the code template

Hi, welcome! :wave:

Sounds like a scam contract, lol.

I think when you sell tokens, the token will be sent to the pair address, so just add an extra judgement, such as:

require(to != PAIR_ADDRESS);

Hello can you give me your mail or your telegram, if I need further assistance. Thanks

Hey, you can just ask at here, all talk should be public, so others who has the same question like you can get a quick answer.

Smells fishy !!! Same as was SQUID TOKEN ... scam contracts shouldnt be supported !

You can drop your telegram id or e mail, I have the full code

The link to my telegram is

Check Telegram,
I have drop message