Profile

Cover photo
David Crawshaw
Works at Google
4,086 followers|147,319 views
AboutPostsPhotosVideosReviews

Stream

 
London Bridge
For those of you who have heard cultural references to London Bridge, then went to London, saw it, and couldn't work out what the fuss was about: the bridge used to be interesting.

On the south is a bridge of stone eight hundred feet in length, of wonderful work; it is supported upon twenty piers of square stone, sixty feet high and thirty broad, joined by arches of about twenty feet diameter. The whole is covered on each side with houses so disposed as to have the appearance of a continued street, not at all of a bridge. -- Paul Hentzner, 1598
5
Lea Kissner's profile photo
 
It doesn't look like that anymore? I'm disappointed.
Add a comment...

David Crawshaw

Shared publicly  - 
 
Apparently to use the new C++ chrono library to do something common, say, calculate the wall time of a function, you must first parameterize your time points by the kind of clock you want:

    std::chrono::time_point<std::chrono::system_clock> start, end;
    start = std::chrono::system_clock::now();
    std::cout << "f(42) = " << fibonacci(42) << '\n';
    end = std::chrono::system_clock::now();
    std::chrono::duration<double> elapsed_seconds = end-start;
 
Who thought this kind of complexity was a good idea in a standard library? The rare users who need different clocks will write their own time libraries.

The Go equivalent:

    start := time.Now()
    fmt.Println("f(24) = ", fibonacci(24))
    end := time.Now()
    elapsed := end.Sub(start)
1
Nicholas Dunn's profile photoJamie Spence's profile photo
2 comments
 
The sub-namespace is rather cumbersome but adding using namespace std::chrono; helps. If you're going to use C++11 libraries, why not use C++11 style? Simply: 

    auto start = system_clock::now();
    std::cout << "f(42) = " << fibonacci(42) << '\n';
    auto end = system_clock::now();
    auto elapsed_seconds = end-start;
Add a comment...

David Crawshaw

Shared publicly  - 
 
Google offices in Zurich are well stocked.
7
Elena Revolon's profile photo
 
Is it good for you?
Add a comment...
 
Every time I meet a neuroscientist, I ask who is working on this. It's wonderful that someone is seriously thinking about it.

Neural Dust: An Ultrasonic, Low Power Solution for Chronic Brain-Machine Interfaces http://arxiv.org/pdf/1307.2196v1.pdf

Sadly from a followup paper: "The use of embedded local recording and wireless data transmission would only be viable, however, given major improvements to the power efficiency of microelectronic devices."
2
2
Kelli Halliburton's profile photoCyrus Khan's profile photo
Add a comment...

David Crawshaw

Shared publicly  - 
 
"Why did the chicken cross the road?

"It had been crossing so long it could not remember. As it stopped in the middle to look back, a car sped by, spinning it around. Disoriented, the chicken realized it could no longer tell which way it was going. It stands there still."
1
Matt Cruikshank's profile photo
 
Why did the multithreaded chicken cross the road?

to To other side. get the
Add a comment...
Have them in circles
4,086 people

David Crawshaw

Shared publicly  - 
 
One last morning in Paris.
3
Add a comment...

David Crawshaw

Shared publicly  - 
 
Afternoon run in Zurich.
9
Add a comment...

David Crawshaw

Shared publicly  - 
 
A new comic sans for a new century.
1
Add a comment...

David Crawshaw

Shared publicly  - 
 
Morning run in Dijon.
4
1
Dave Besbris's profile photoElena Revolon's profile photo
 
Lovely
Add a comment...

David Crawshaw

Shared publicly  - 
 
"If you want to build a ship, don't drum up people to collect wood and don't assign them tasks and work, but rather teach them to long for the endless immensity of the sea."
--Antoine de Saint Exupéry
7
Add a comment...
People
Have them in circles
4,086 people
Work
Occupation
Software Engineer
Employment
  • Google
    Staff Software Engineer, 2010 - present
    Go team
Story
Tagline
Programmer
Introduction
Links
Other profiles
Public - 3 months ago
reviewed 3 months ago
Public - 4 months ago
reviewed 4 months ago
The best italian hybrid pizza I have found in the Bay Area. The crust is a little thicker than a standard Italian pizza, but it errs on the right side and is consistently excellent. Margharita is all you need.
Food: ExcellentDecor: Very goodService: Very good
Public - a year ago
reviewed a year ago
Tapas. Meat focused, excellent calamari and excellent ham. Wine selection exceeds expectations.
Food: ExcellentDecor: Very goodService: Very good
Public - a year ago
reviewed a year ago
6 reviews
Map
Map
Map
Public - 5 months ago
reviewed 5 months ago
24-hour glazed donuts.
Food: Very goodDecor: GoodService: Very good
Public - a year ago
reviewed a year ago