Can we send tokens with data input? I did a bit of research on erc20 but maybe this is quite complicated. Will erc 721 do this?
ERC20 and ERC721 are, by definition, interfaces.
You cannot attach extra data to the prescribed functions, e.g.
transfer() because that will break compatibility with the standard interface.
You didn't say what you want to achieve so it's not possible to be specific about the solution. Two common approaches spring to mind.
ERC20 is for fungible assets - every instance is materially equal to the others. You can use this to represent a medium of exchange (e.g. currency), fractional ownership, general-admission seating, etc. You can separate the "extra data" into a separate function or separate contract that deals with both the extra data and the exchange of tokens.
ERC721 is for non-fungible assets - every instance is unique and materially different from the others, e.g. collectables, cryptokitties, reserved seating, etc. ERC721 deals with common functions, again
transfer() and it is silent on the matter of metadata associated with each token.
A housekey would be an example. Such a thing can use a common set of rudimentary functions (e.g.
transfer() from Alice to Bob) and custom metadata suitable to the application. The shape of the teeth is unique in each instance. ERC721 allows the introduction of additional functions (e.g.
cutKey()) that can write to the arbitrary metadata of each instance.
Hope it helps.