Live data from Hacker News

“What happens when you type Google.com into your browser and press enter?”

github.com

1–10 of 136 posts

Re: “What happens when you type Google.com into your browser and press enter?”

#3
The first part is already outdated. A lot depends on the browser. Chrome will look up stuff as you type it, and by the time you press , the DNS lookup will likely have happened already. And, likely, the actual request to the page.

It's probably even more complicated than that, I believe "google.com" is a very special case in Chrome.

Re: “What happens when you type Google.com into your browser and press enter?”

#4
> The keyboard controller then encodes the keycode for transport to the computer. This is now almost universally over a Universal Serial Bus (USB) connection, but historically has been over PS/2 or ADB connections.

What about Bluetooth keyboards?

Re: “What happens when you type Google.com into your browser and press enter?”

#5
Love it! One of my favourite bad interview questions. I got asked this in an interview ~5 years ago. My response was to look shocked... Pause. Then ask: "What do you mean? What detail do you need? DNS? SYN / ACK? HTTP?"

At the point I started talking about syn/acks they just cut me off and moved on to the next question.

Same company (different person) started the phone screen with 'oh so your CV says you know linux, what's the difference between a hard link and a soft link' and was shocked when I knew the answer, declaring the rest of the phone interview pretty pointless - he'd obviously had a bad morning and started with his hardest question.

I've now learnt to see such interview questions as a sign of a workplace with little-to-no learning on the job. Most places that actively encourage learning don't try such things.

Re: “What happens when you type Google.com into your browser and press enter?”

#7
Computerphile made a good vide on the same subject ~a month ago called "What Happens When You Click a Link?" [1]

It is obviously not as deep in content as the article is aiming to be, specially because it focus only on the first things that happens like DNS resolving and the socket connection, however, it is still fun video.

[1] https://www.youtube.com/watch?v=keo0dglCj7I

Re: “What happens when you type Google.com into your browser and press enter?”

#8
post #5

Love it! One of my favourite bad interview questions. I got asked this in an interview ~5 years ago. My response was to look shocked... Pause. Then ask: "What do you mean? What detail do you need? DNS? SYN / ACK? HTTP?" At the point I started talking about syn/acks they just cut me off and moved on to the next question. Same company (different person) started the phone screen with 'oh so your CV says you know linux,…

I'm not so sure it's a bad interview question. Or rather, perhaps it's only bad if you, as the interviewer, have a specific answer in mind.

We used it once with the caveat that "there's no right answer, we don't really know every step either, lets see what happens". We collaborated with them, it was great, and by the end of the conversation were pretty certain we wanted to keep the conversation going by hiring them.

Set your expectations accordingly, I suppose.

Re: “What happens when you type Google.com into your browser and press enter?”

#9
There is also a very good introductory answer in this subject by Jean-Baptiste Quéru in 2013 [1] where he takes the revers approach of when the page is displayed, then talks about connection, OS, etc. "simplifying" the answer and going down several levels of abstraction and complexities to give the proper overwhelming sense that this question should impose.

It is a very fun text to read and I really recommend it.

[1] https://plus.google.com/u/0/+JeanBaptisteQueru/posts/dfydM2C...

Re: “What happens when you type Google.com into your browser and press enter?”

#10
post #5

Love it! One of my favourite bad interview questions. I got asked this in an interview ~5 years ago. My response was to look shocked... Pause. Then ask: "What do you mean? What detail do you need? DNS? SYN / ACK? HTTP?" At the point I started talking about syn/acks they just cut me off and moved on to the next question. Same company (different person) started the phone screen with 'oh so your CV says you know linux,…

I'm not so sure it's a bad interview question. Or rather, perhaps it's only bad if you, as the interviewer, have a specific answer in mind. We used it once with the caveat that "there's no right answer, we don't really know every step either, lets see what happens". We collaborated with them, it was great, and by the end of the conversation were pretty certain we wanted to keep the conversation going by hiring them.…

I agree with this completely. I think the point of all interviews should be to start a conversation - and the sort of broad technical conversation this question inspires is a really good way to see both what candidates know and how they communicate it.

I've had candidates fail to explain the distinction between the client and the server. I had one candidate exclaim "I hoped you'd ask this" and jump straight into a discussion on the parsing of cache-control headers by proxy servers.

Post reply on HN