Noel Constant did it without genius and without spies.
His system was so idiotically simple that some people can't understand it, no matter how often is is explained. The people who can't understand it are people who have to believe, for their own peace of mind, that tremendous wealth can be produced only by thremendous cleverness.
This was Noel Constant's system:
He took the Gideon Bible that was in his room, and he started with the first sentence in Genesis.
The first sentence in Genesis, as some people may know, is: "In the beginning God created the heaven and the earth." Noel Constant wrote the sentence in capital letters, put periods between the letters, divided the letters into pairs, rendering the sentence as follows: "I.N., T.H., E.B., E.G., I.N. N.I., N.G., G.O., D.C., R.E., A.T., E.D., T.H., E.H., E.A., V.E., N.A., N.D., T.H., E.E., A.R., T.H."
And then he looked for corporations with those initials, and bought shares in them. His rule at the beginning was that he would own shares in only one corporation at a time, would invest his whole nest-egg in it, and would sell the instant the value of his shares had doubled.
–Kurt Vonnegut, Sirens of Titan
The investor Noel Constant is getting tired of using his system manually. He needs the power of computers to pick the companies to invest in.
Noel Constant is willing to learn how to execute a command line script or a function in the language of your choice. He will provide a single string of input. He won't bother removing any whitespace, punctuation, or change case for the input string. He doesn't like that kind of work.
In return he expects to see a list of companies he can invest in, produced
according to his idiotically simple system. He wants to see each company on its
own line with the initials in brackets. If there isn't a company with the
initials needed he wants to see three dots (...
).
International Nitrate (IN)
Throwbridge Helicopter (TH)
Electra Bakeries (EB)
Eternity Granite (EG)
... (IN)
His company, Magnum Opus, provided a list of company names and their initials for you: https://gist.github.com/britishtea/2f57710a114cfd79616d.
As you may have guessed, Noel Constant doesn't like reading, so he'll want the shortest program or function possible.
EDIT
To clarify, the input to the function or program is string (with punctuation and whitespace, case unaltered). An example of such a string is "In the beginning God created the heaven and the earth." The list of company names and initials is not an input source, it should be read some other way (from disk for example).
The output is a list in the above format. I forgot to mention in the original challenge that the order the company names appear in shouldn't be altered, i.e. if you read the initials in the output from top to bottom it renders the original input (stripped of punctuation and whitespace).
This is no longer a requirement, but if your function or program satisfies this condition, there is a 0.9
bonus (# characters * 0.9
) in it for you.