Skip to content

Instantly share code, notes, and snippets.

View vinayak-mehta's full-sized avatar
🤕
Recovering

Vinayak Mehta vinayak-mehta

🤕
Recovering
View GitHub Profile

Can money set you free?

By John Lanchester

Published: January 29 2010 16:50 | Last updated: January 29 2010 16:50

In 1982, partway through my first year at Oxford university, my father asked me a question that took me by surprise. He said, “Do you have enough money?”

It took me by surprise partly because it is somehow, in and of itself, a surprising question - not one that people often ask. What’s enough? We don’t ask ourselves that very often. I thought about what he’d asked for a moment and then said, truthfully, “I never think about money.” He laughed and said, “Then you’re rich.”

The Iraqi who saved Norway from oil

By Martin Sandbu

Published: August 29 2009 02:26 | Last updated: August 29 2009 02:26

When he boarded his flight from London to Oslo, Farouk al-Kasim, a young Iraqi geologist, knew his life would never again be the same. Norway was a country about as different as it was possible to imagine from his home, the Iraqi port city of Basra. He had no job to go to, and no idea of how he would make a living in the far north. It was May 1968 and al-Kasim had just resigned from his post at the Iraq Petroleum Company. To do so, he had had to come to the UK, where the consortium of western companies that still controlled most of his country’s oil production had its headquarters.

For all its uncertainties, al-Kasim’s journey to Norway had a clear purpose: he and his Norwegian wife, Solfrid, had decided that their youngest son, born with cerebral palsy, could only receive the care he needed there. But it meant turning their backs on a world of comforts. Al-Kasim’s successful career ha

I was drawn to programming, science, technology and science fiction
ever since I was a little kid. I can't say it's because I wanted to
make the world a better place. Not really. I was simply drawn to it
because I was drawn to it. Writing programs was fun. Figuring out how
nature works was fascinating. Science fiction felt like a grand
adventure.
Then I started a software company and poured every ounce of energy
into it. It failed. That hurt, but that part is ok. I made a lot of
mistakes and learned from them. This experience made me much, much
@entropiae
entropiae / Install pyenv on Ubuntu 18.04 + fish shell
Last active September 20, 2024 22:12
Install pyenv on Ubuntu 18.04 + Fish shell
Install pyenv on Ubuntu 18.04 + fish shell
- Install the packages required to compile Python
$ sudo apt-get update; sudo apt-get install --no-install-recommends make build-essential libssl-dev zlib1g-dev libbz2-dev libreadline-dev libsqlite3-dev wget curl llvm libncurses5-dev xz-utils tk-dev libxml2-dev libxmlsec1-dev libffi-dev liblzma-dev
- Download pyenv code from github
$ git clone https://github.com/pyenv/pyenv.git ~/.pyenv
- Define environment variable PYENV_ROOT to point to the path where pyenv repo is cloned
$ echo "set --export PYENV_ROOT $HOME/.pyenv" > ~/.config/fish/conf.d/pyenv.fish
@jboner
jboner / latency.txt
Last active November 15, 2024 14:00
Latency Numbers Every Programmer Should Know
Latency Comparison Numbers (~2012)
----------------------------------
L1 cache reference 0.5 ns
Branch mispredict 5 ns
L2 cache reference 7 ns 14x L1 cache
Mutex lock/unlock 25 ns
Main memory reference 100 ns 20x L2 cache, 200x L1 cache
Compress 1K bytes with Zippy 3,000 ns 3 us
Send 1K bytes over 1 Gbps network 10,000 ns 10 us
Read 4K randomly from SSD* 150,000 ns 150 us ~1GB/sec SSD