The function checks whether the input string belongs to a specific category such as fruit, number, or sentence.

