Appellant Elaine Stevens was charged with both purchase and possession of cocaine. It is undisputed that the two offenses involved a single quantity of cocaine. Therefore the trial court erred in denying appellant’s motion to dismiss the possession charge. Lewis v. State, 545 So.2d 427 (Fla. 2d DCA), jurisdiction accepted, 550 So.2d 467 (Fla.1989).
Following an adverse ruling on her motion appellant entered a plea of no contest. Adjudication of guilt was withheld *786and she was placed on probation. The trial court imposed court costs without prior notice or hearing. We therefore strike the cost provision without prejudice to the state to seek reassessment after proper notice. Wood v. State, 544 So.2d 1004 (Fla.1989).
Apart from the cost provision the sanction imposed for purchase of cocaine is not challenged on appeal and is affirmed.
Affirmed in part, reversed in part, and remanded with instructions.
FRANK, A.C.J., and THREADGILL and PATTERSON, JJ., concur.