Programmatically determine whether to describe an object with "a" or "an"?
- by MarathonStudios
I have a database of nouns (ex "house", "exclamation point", "apple") that I need to output and describe in my application. It's hard to put together a natural-sounding sentence to describe an item without using "a" or "an" - "a house is BIG", "an exclamation point is SMALL", etc.
Is there any function, library, or hack i can use in PHP to determine whether it is more appropriate to describe any given noun with A or AN?