<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en-GB">
	<id>https://stockhub.co/index.php?action=history&amp;feed=atom&amp;title=Module%3AA_or_an</id>
	<title>Module:A or an - Revision history</title>
	<link rel="self" type="application/atom+xml" href="https://stockhub.co/index.php?action=history&amp;feed=atom&amp;title=Module%3AA_or_an"/>
	<link rel="alternate" type="text/html" href="https://stockhub.co/index.php?title=Module:A_or_an&amp;action=history"/>
	<updated>2026-04-16T17:45:00Z</updated>
	<subtitle>Revision history for this page on the wiki</subtitle>
	<generator>MediaWiki 1.43.5</generator>
	<entry>
		<id>https://stockhub.co/index.php?title=Module:A_or_an&amp;diff=133162&amp;oldid=prev</id>
		<title>imported&gt;Nardog at 19:06, 18 May 2020</title>
		<link rel="alternate" type="text/html" href="https://stockhub.co/index.php?title=Module:A_or_an&amp;diff=133162&amp;oldid=prev"/>
		<updated>2020-05-18T19:06:15Z</updated>

		<summary type="html">&lt;p&gt;&lt;/p&gt;
&lt;p&gt;&lt;b&gt;New page&lt;/b&gt;&lt;/p&gt;&lt;div&gt;local p = {}&lt;br /&gt;
local words = mw.loadData(&amp;#039;Module:A or an/words&amp;#039;)&lt;br /&gt;
&lt;br /&gt;
local lcVChars = &amp;#039;aeiouà-æè-ïò-öø-üāăąēĕėęěĩīĭįıĳōŏőœũūŭůűų&amp;#039;&lt;br /&gt;
local ucVvChars = &amp;#039;AEFHILMNORSXÀ-ÆÈ-ÏÒ-ÖØĀĂĄĒĔĖĘĚĨĪĬĮıĲŌŎŐŒÑĤĦĹĻĽĿŁŃŅŇŊŔŖŘŚŜŞ&amp;#039;&lt;br /&gt;
&lt;br /&gt;
local function findWord(s, t)&lt;br /&gt;
	for i, v in ipairs(t) do&lt;br /&gt;
		if mw.ustring.find(s, &amp;#039;^&amp;#039; .. v .. &amp;#039;$&amp;#039;) then&lt;br /&gt;
			return true&lt;br /&gt;
		end&lt;br /&gt;
	end&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
function p._main(args)&lt;br /&gt;
	local s = args[1] and mw.text.trim(args[1])&lt;br /&gt;
	local pron = &amp;#039;a&amp;#039;&lt;br /&gt;
	local ret = &amp;#039;&amp;#039;&lt;br /&gt;
	&lt;br /&gt;
	if s and s ~= &amp;#039;&amp;#039; then&lt;br /&gt;
		local origStr = s&lt;br /&gt;
		&lt;br /&gt;
		s = mw.ustring.gsub(s, &amp;#039;&amp;lt;/?[A-Za-z][^&amp;gt;]-&amp;gt;&amp;#039;, &amp;#039;&amp;#039;) -- Remove HTML tags&lt;br /&gt;
		s = mw.ustring.gsub(s, &amp;#039;%[%[[^%|]+%|(..-)%]%]&amp;#039;, &amp;#039;%1&amp;#039;) -- Remove wikilinks&lt;br /&gt;
		s = mw.ustring.gsub(mw.ustring.gsub(s, &amp;#039;%[%[&amp;#039;, &amp;#039;&amp;#039;), &amp;#039;%]%]&amp;#039;, &amp;#039;&amp;#039;)&lt;br /&gt;
		s = mw.ustring.gsub(s, &amp;#039;^[&amp;quot;%$\&amp;#039;%(&amp;lt;%[%{¢-¥₠-₿]+&amp;#039;, &amp;#039;&amp;#039;) -- Strip some symbols at the beginning&lt;br /&gt;
		s = mw.ustring.match(s, &amp;#039;^%.?[0-9%u%l]+&amp;#039;) or s -- Extract the first word&lt;br /&gt;
		&lt;br /&gt;
		if mw.ustring.find(s, &amp;#039;^[0-9]&amp;#039;) then -- It begins with a number&lt;br /&gt;
			s = mw.ustring.match(s, &amp;#039;^[0-9]+&amp;#039;) -- Extract the number&lt;br /&gt;
			if findWord(s, words.vNums) then -- &amp;#039;18&amp;#039; etc.&lt;br /&gt;
				pron = &amp;#039;an&amp;#039;&lt;br /&gt;
			end&lt;br /&gt;
		elseif mw.ustring.match(s, &amp;#039;^[0-9%u]+$&amp;#039;) then -- It looks like an acronym&lt;br /&gt;
			if mw.ustring.find(s, &amp;#039;^[&amp;#039; .. ucVvChars .. &amp;#039;]&amp;#039;)&lt;br /&gt;
				and not findWord(s, words.cvAcronyms) -- Exclude &amp;#039;NASA&amp;#039; etc.&lt;br /&gt;
				or findWord(s, words.vvAcronyms) -- &amp;#039;UNRWA&amp;#039; etc.&lt;br /&gt;
			then&lt;br /&gt;
				pron = &amp;#039;an&amp;#039;&lt;br /&gt;
			end&lt;br /&gt;
		else&lt;br /&gt;
			s = mw.ustring.lower(s) -- Uncapitalize&lt;br /&gt;
			if mw.ustring.find(s, &amp;#039;^[&amp;#039;.. lcVChars .. &amp;#039;]&amp;#039;) then -- It begins with a vowel&lt;br /&gt;
				if not findWord(s, words.vcWords) -- Exclude &amp;#039;euro&amp;#039; etc.&lt;br /&gt;
					or findWord(s, words.vvWords) -- But not &amp;#039;Euler&amp;#039; etc.&lt;br /&gt;
				then&lt;br /&gt;
					pron = &amp;#039;an&amp;#039;&lt;br /&gt;
				end&lt;br /&gt;
			elseif args.variety and mw.ustring.lower(args.variety) == &amp;#039;us&amp;#039; -- &amp;#039;herb&amp;#039; etc.&lt;br /&gt;
				and findWord(s, words.cvWordsUS)&lt;br /&gt;
				or findWord(s, words.cvWords) -- &amp;#039;hour&amp;#039; etc.&lt;br /&gt;
			then&lt;br /&gt;
				pron = &amp;#039;an&amp;#039;&lt;br /&gt;
			end&lt;br /&gt;
		end&lt;br /&gt;
		ret = pron .. &amp;#039; &amp;#039; .. origStr&lt;br /&gt;
	end&lt;br /&gt;
	&lt;br /&gt;
	return ret&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
function p.main(frame)&lt;br /&gt;
	return p._main(frame:getParent().args)&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
return p&lt;/div&gt;</summary>
		<author><name>imported&gt;Nardog</name></author>
	</entry>
</feed>