4 ms·
> if word.startswith("ub"): return False An uber-rich man riding in an Uber installed an Ubuntu package. I'm actually a bit surprised by this rule. Is this
by bugufu8f83 13d ago
> if word.startswith("ub"): return False
An uber-rich man riding in an Uber installed an Ubuntu package.
I'm actually a bit surprised by this rule. Is this line there entirely due to the word "ubiquitous"? I think it is.
- ExoticPearTree 13d agoTo keep it simple, you use an when the first letter of the next word sounds like a vowel when pronounced (vowel sound) and appplies to ancronyms too. Otherwise you use a.
- xattt 13d ago“An MRI report“ vs “a yogurt container”.
- 0manrho 13d agoThe MRI example is perfect, but I feel like the yogurt one is a bad example given the "and sometimes Y" (is a vowel) thing, or do we just ignore that for a vs an? Like in this context, do we always treat Y when pronounced like "Yes" or "Yogurt" as a consonant?
- ExoticPearTree 13d agoBecause “an youghurt container” sounds wrong. English has this thing where you know you wrote or pronounced something correct if it sounds right.
- deleted 13d ago[deleted]
- deleted 13d ago[deleted]
- deleted 12d ago[deleted]
- drdec 12d agoBecause vowels are sounds, not letters
- gertrunde 13d agoThe one that I often find irritating is SQL... An "ess queue ell", but a "sequel". :(
- bugufu8f83 13d agoYes, I'm well aware. I'm responding to the code in the OP's article (you need to click through the link at the bottom of the HN submission--I have no idea why the OP blog has two separate pages for this).
- mrweasel 13d agoThat is probably on of the most confusing things about English. What do you mean "sounds like a vowel"? All vowels sound like vowels, what else would they sound like? While we're at the subject, why is Y not a vowel (except when it is) and why can you have more than one vowel in a syllable. In the example in the article they have unicorn, which is clearly spelled wrong if English were to make sense. The correct spelling should be "junicorn". Fixed. Counting the number of syllables in a language like Danish means you just count the number of vowels. A syllable must have one, and only one, vowel. A word like "you", if it existed in Danish, would have three syllables, because all those letters are vowels, at any point in time.
- ExoticPearTree 13d agoFor example “I have an MBA” and “I know a mechanic”. When you pronounce the M from MBA, you hear the e in front, you’re saying em-bi-a. But for mechanic, you just have a stromg m. This is what I mean by “if it sounds like a vowel”. And hence an and a.
- deleted 13d ago[deleted]
- wartijn_ 13d agoTwo of the three words in your example are proper names, which the author decided not to include. The full "ub" list in cmudict is: ubben uber ubiquitous ubiquity ubuntu Ubben is a name as well, so it should leave us with uber, ubiquitous and ubiquity. I think uber might have been dropped by accident because of Uber.
- amitp 13d agoI think it'd be reasonable to keep uber, but I had dropped it because it wasn't in /usr/share/dict/words on Linux or Mac. That was a quick&dirty way to filter out proper names, but it misses some other words too.
- wartijn_ 12d agoI was wondering why you involved that dictionary, but this makes sense.
- Aachen 13d agoFor anyone else wondering what the problem is supposed to be with that example: some English speakers call ubuntu "you buntu" whereas uber is just pronounced, well, as you write it and not "youber" I used Ubuntu before learning English so it took me a while to realise
- amitp 13d agoI added the word list to the main article. The rule is for two words, ubiquitous and ubiquity, so maybe the rule should be tightened to word.startswith("ubiqu"). Uber and Ubuntu are not in my word list (which attempts to exclude proper nouns), but maybe I should add uber, uberant, uberous, uberously, uberousness, uberty, uberties. I had a self-imposed time limit of 1 day for this side quest, but there are lots of ideas in the comments here so someday I may come back to this project and give it another day.