3 Jun 2012
Timeline of significant financial events
An evolving timeline of financial events.
The professional portfolio of James Jack
24 May 2012
Since I come from a computer science background it’s important to build my knowledge and awareness of financial topics, definitions and insights. This article will be a working document that will continue to be modified over time.
8 May 2012
It is intriguing that some of the most important technological advances in history were made due to chance. For instance, no one ever sat down and planned the invention of Penicillin (the first antibiotic) because it was a discovery – that is, a result of something that was not planned – something that happened accidentally but someone sat up and took note of what was happening in front of them. So really this is a list of things that were never planned.
3 May 2012
If I think of a number between 1 and 1000, what’s the minimum number of guesses required if you are given a hint “higher” or “lower” for each guess?
3 May 2012
You need to cut a birthday cake into 8 equal pieces. But you can only slice the cake 3 times. How do you do it?
3 May 2012
Joe Bloggs wants to hack into someone’s email account: he knows their name and roughly where they come from, and maybe what university they went to. Without any programming, how does he access your password-protected yahoo email?
28 Apr 2012
If there is a wind blowing, would a round-trip by plane take more time, less time, or the same amount of time than on a still day?
5 Dec 2011
Suppose you lay out a long line of coins, all facing heads up, and number them 1, 2, 3, …
Suppose that you then go and flip over the 2nd, 4th, 6th, 8th, … coins. (You would then have a pattern H T H T H T H T… )
Then you go and flip over the 3rd, 6th, 9th, 12th, … coins. (You would then have H T T T H H…)
And then you go and flip over the 4th, 8th, 12th, 16th, … coins.
And so on.
Which of the coins will remain heads up, and why?
10 Nov 2011
The simple approach to trading is to buy some shares and then sell them later.
For instance: I could buy 1000 shares of NVDA (Nvidia Corp.) at $10, wait for the price to ramp up, and later sell the shares at $15, making a hearty $5000 profit (minus transaction fees).
Short selling is the reverse of this process: you sell the shares first and then buy them later.
But how can you possibly sell shares that you don’t have? Well, when you initiate a short sell, your broker borrows the shares from one of its retail customers and sells it on the market. Your account is credited with the proceeds, however you owe them the shares back. At a later point in time, you decide to cover your position by buying the stock, and the shares are returned to the retail customer.
So to continue the previous example, if we short (sell) 1000 shares of NVDA at $10, wait a little while, and then buy to cover the 1000 shares at $15, we make a loss of $5000. So when shorting, we are interested in the price going down rather than up!
I.e. even in bear markets you can make a profit.
8 Nov 2011
I got asked this question during a technical interview for Bloomberg:
You have a piece of hardware that generates random 0’s and 1’s at your request. How would you use it to generate random numbers between 0 and 199 (200 values)?
The obvious problem here is the set of values you’re interested in; had it been 0 to 255, then you only need to bung 8 bits in a byte and you’re done. But in this case we need to be careful and make sure the generator has a uniform distribution.
0 = 00000000 in binary 199 = 11000111 in binary
During the interview, I said that you generate a byte’s worth of random numbers, and if the number is above 199, then simply query the hardware again until you get one below 199. The obvious flaw to this is that you might be unfortunate and have to call the function hundreds of times, theoretically up to an infinite number of times! However, in practice this is a suitable approach, and you are assured of it being a uniform distribution. That answer was accepted.
What’s the chance of having to re-call the function 20 times in a row? About (56/255)^20 = 6.81e-14. That means, if you called the RNG 100,000 times a second, on average this worst-case would happen once in every 5 years.