It could be an ulcer on your tongue. This can happen due to various reasons. You need to consult either a Physician or ENT specialist . Till then maintain good oral hygiene .
Next Steps
use a mouthwash to keep the ulcer and surrounding area clean.
Health Tips
keep a track of such symptoms. see if this happens on regular basis or coincides with other body disturbances, or your menstrual cycle . consult doctor soon