These kids must be 21, tops. His main complaint? She doesn’t clean the dishes when his mom asks her to.
Andy Boyle lives tweets a breakup at a Burger King. (via Future Jess Kimball)
These kids must be 21, tops. His main complaint? She doesn’t clean the dishes when his mom asks her to.
Andy Boyle lives tweets a breakup at a Burger King. (via Future Jess Kimball)
Under my plan, each American household could borrow $10 million from the Fed at zero interest. The more conservative among us can take that money and buy 10-year Treasury bonds. At the current 2 percent annual interest rate, we can pocket a nice $200,000 a year to live on.
Two things stand out to me: Instagram’s efficiency at 2.6M users per employee, and the relatively small userbases of some of the acquisitions (Jaiku only had 50k?).
I write code where I’m given an object of some class (usually from a library call), but I wish to use additional methods on that class as though they had been defined there.
He’s a little light on the details of what he’s trying to accomplish exactly — the solution he provides ends up leaving the original instance untouched. If it’s ok to modify the original instance (or its class), then a more elegant solution might be:
class Base(object):
def __init__(self):
self.base_init = True
def foo(self):
return 'base foo'
def bar(self):
return 'base bar'
def child_bar(self):
return 'child bar'
b = Base()
# this overwrites all instances of from this point on.
Base.bar = child_bar
print b.bar() # prints 'child bar'
# this overwrites the foo function of just an instance of Base
import types
def child_foo(self):
return 'child foo'
b.foo = types.MethodType(child_foo, b, b.__class__)
print b.foo() # prints 'child foo'
b_orig = Base()
print b_orig.foo() # prints 'base foo'
In the first example, I’ve overwritten the bar method for all instances of class Base. In the second example, I’ve overwritten the foo method for just a single instance of Base. Admittedly, the types.MethodType call is a bit clunky (and I’ve never been able to commit it to memory, thank goodness for Google), but you could easily throw that into a handy function or decorator.
[Having the first 1G iPhone] felt like I was on Star Trek and this was my magical tricorder… a tricorder that constantly dropped calls on AT&T’s network, had a headphone adapter that didn’t fit any of the hundreds of dollars of headphones I owned, ran no applications, had no copy and paste, and was as slow as molasses.
Classic essay, and origin (as far as I know) of the phrase, “if you’re not embarrassed by your first version, you’ve waited too long to launch”. Apple products are usually held up as pinnacles of product and industrial design, so it’s easy to forget they were once (and still are) flawed.
Really fantastic collection of textured backgrounds, free for any use. I looked around for something like this a little while ago and couldn’t find anything that looked particularly good. Very glad to see this!
(via Swissmiss)
Turns out optimizing the CSS selectors on a page doesn’t make much of a difference in real world cases.