First of all with fruits there is an additional problem of orla besides the issue of teruma and maaser, and you should not purchase fruits without a reliable hechsher unless you know which species are likely to be orla and which are not.
For vegetables the procedure is to first get hold of a peruta chamura, a coin that has been specially designated for the purpose. There is an organization that takes care of this, but I don't have their contact info handy. You must separate at least 1% of the produce and say the formula usually printed in the back of the siddur. It is important to understand what you are saying, read through it before you actually are separating terumos and maaser and ask someone to help you if any of the concepts are unfamiliar. The produce you separated should be double-wrapped, and then it may be disposed.