39 ms·
Australian software engineer got asked algorithm question when entering US
- lstamour 10y agoOriginal, with a little bit more detail: http://www.news.com.au/travel/travel-advice/travellers-stories/aussies-weird-immigration-interview-in-the-us/news-story/8222c65d2f12e6691ef27c9b1753e821 http://www.news.com.au/travel/travel-advice/travellers-stori... > “The vibe I got was weird. He asked me a question, then asked me a follow-up question to prove I wasn’t lying. > “Do they not allow bad software engineers into the United States?” Thornton joked. See also, more recently: http://money.cnn.com/2017/03/02/technology/andela-engineer-customs/index.html http://money.cnn.com/2017/03/02/technology/andela-engineer-c...
- ericdykstra 10y agoPeople are quick to blame this on Trump, but reading through the comments on a previous article for this incident (http://www.news.com.au/travel/travel-advice/travellers-stories/aussies-weird-immigration-interview-in-the-us/news-story/8222c65d2f12e6691ef27c9b1753e821 http://www.news.com.au/travel/travel-advice/travellers-stori...), it looks like it’s par for the course to test someone’s knowledge on their claimed profession. Here’s a comment from one of the users: > Had the same experience 12 years ago: admitted I am developing linux device drivers, and had to explain differences between kernel 2.4 and 2.6 APIs. The guy actually understood it. Testing occupational expertise is not a bad way to find people who are lying. To be able to explain the difference between kernel 2.4 and 2.6 APIs or how to balance a binary search tree are questions one could not possibly answer without actually being in that profession. Let’s say you’re a hitman traveling to Malaysia to take out the estranged brother of a dictator. Before you go, you’re given a fake passport and character sheet telling you your profession, your family situation, etc. It’s pretty easy to answer questions like “how long have you been working as a photographer?” or “how did you meet your wife?” but a lot more difficult to prepare for questions like “What is the best lense for close ups?”
- rl3 10y ago>Let’s say you’re a hitman traveling to Malaysia to take out the estranged brother of a dictator. Before you go, you’re given a fake passport and character sheet telling you your profession, your family situation, etc. It’s pretty easy to answer questions like “how long have you been working as a photographer?” or “how did you meet your wife?” but a lot more difficult to prepare for questions like “What is the best lense for close ups?” Hopefully for the estranged brother, Mr. Hitman doesn't happen to enjoy a photography hobby in his spare time. :) Then again, high-end assassins are probably adept at photography anyways. Part of their job is planning, and that involves surveilling targets prior.
- mattnewton 10y agoAnd really, how hard is it to troll Wikipedia beforehand? Or to just say you are a taxi driver / stylist / etc?
- ubernostrum 10y agoWhether it's "par for the course" or not, this requires us to trust that every immigration officer in service is enough of an expert in every field of endeavor to A) come up with relevant questions and B) judge quality of answers. The likelihood of that being true is incredibly low. What's worse, we know that typically people specialize within fields; a kernel hacker probably knows nothing whatsoever about using Ruby on Rails, but that might be the question the border agent googles up (or the web dev might get asked about kernel APIs). Plus: making excuses for this makes you complicit in whatever evil it begets, so maybe you should stop making excuses for it.
- stoolpigeon 10y agoEvil? Getting hassled by immigration is evil? You should travel with my Albanian friends. Apparently every immigration person in the world is evil.
- ubernostrum 10y ago
- dmitrykoval 10y agoIt's a little bit strange that even though Python was mentioned there's not a hint about the actual problem in question.
- curryhowardiso 10y agoI didn't tell the journalists the question because it wouldn't mean anything to their target audience. Most of these reposts (including this one in hacker news) have not reached out to me for additional or audience-specific details :)
- kirillkh 10y agoThis makes me wish some of my colleagues were issued an airplane ticket to the US. Possibly one-way.
- d--b 10y agoIt's actually fairly typical. When you enter on a H1B visa they ask you questions to see if your occupation (the one you got the visa for) is not made up. I work in Finance, and when I was on a H1B visa (back in 2010), the immigration officer asked me some bond-related questions, just to see if I had any clue. They also asked my wife what I was working on. It's pretty annoying to feel that you're not being trusted, but yes, they don't trust you. Also the fact that he's Australian is a reassuring proof they don't base these question on color of skin...
- lb1lf 10y ago> Also the fact that he's Australian is a reassuring proof they don't base these question on color of skin... -To their credit, looking caucasian while coming from Australia strongly suggest that your family has a history of trouble with the authorities... ;)
- vacri 10y agoThe last convict ship to Australia sailed 10 years before the US Civil War, and even then it'd been tailing off for decades. White Americans are closer to being slavers than white Australians are to being convicts. Besides, if you want to see who is more criminal-ey in the modern era, the US wins there with a 5x rate of incarceration...
- ubersoldat2k7 10y agoTIL, thanks.
- MarkMc 10y agoAnd a 4x murder rate
- JoeAltmaier 10y agoWait what? The Aborigine genocide has to figure in there somewhere. Add that in, what does the comparison look like?
- lb1lf 10y agoOne cannot but wonder what happens if you answer the question in a different manner than that suggested by Wikipedia or whichever resource the CBP draws their questions from. I think the basic idea - questioning people about things they ought to know, given who they claim to be - is a good one. However, it only makes sense if the one doing the questioning is able to judge the quality of the answer - or, for that matter, determine whether your inability to answer satisfactorily is because you bluffed - or if you're just a bit outside your professional comfort zone. (I would probably have to answer 'software engineer', as that is what my business card says - however, I am much more of a hardware/systems guy in practice, only our HR department is completely unable to change my title to something a bit more descriptive. If speaking to another engineer, I wouldn't have any problems convincing him of my bona fides - however, if a CBP officer just looks up question #13 in the 'SW engineer' quiz - I may be in trouble.
- bbcbasic 10y ago> I think the basic idea - questioning people about things they ought to know, given who they claim to be - is a good one. It's an awful idea. False negatives. Discriminates against people with harder professions. Wouldn't keep out determined people
- lb1lf 10y agoAs to the last part, if people are sufficiently determined, you're in for a hard time, anyway. A 30-second screening at the border is pretty good at sorting out the Epsilon minus semi-morons, though. (Whose numbers, one would suspect, vastly outdoes the really determined ones.) As for false negatives, I wouldn't be too concerned as long as you got to talk to someone reasonably well versed in your field. Also, as suggested by golergka and rconti - they probably use the questions as a way to elicit a response from you and judge that, more than your actual answers. That makes a lot of sense to me, now that I pause to think of it for a second.
- golergka 10y ago> One cannot but wonder what happens if you answer the question in a different manner than that suggested by Wikipedia or whichever resource the CBP draws their questions from. They're looking at your overall attitude, not checking your knowledge of trivia. Answering the question about inverting a binary tree wrongly still means you understand what "binary tree" is and can at least come up with a couple of sentences with that term that sound coherent and resemble what is written in Wikipedia in broadest terms. For comparison, ask your non-engineering friends to answer the same question, even to try to fake an answer as best as they can.
- ericdykstra 10y agoThat's some pretty quick downvoting (2 downvotes in 4 minutes), despite my comment only adding to the story.
- HappyDreamer 10y agoI'm getting the impression that your comment implicitly endorses airport personnel [edit: immigration officers] attempting to find out if people "fake" their occupation. I don't think that wasn't your intention, but that's how the comment looks like, to me. And people reading it might not like that, because airport personnel in general are (I think) likely to do lots of mistakes, if they start trying to verify people's occupations. So traveling somewhere, wold become like rolling a dice — bad luck dice roll = go home again (you happened to meet the wrong & incompetent personnel at the airport). (I didn't downvote.)
- stoolpigeon 10y agoThey aren't airport personnel. They are immigration officers. What I read in the last thread about an incident like this was that they are less interested in the actual answer and more in how you respond. I guess mannerisms can give away things. I know the last time I was pulled aside in US customs and had them go through all my stuff at one point I said, "Sorry, I'm just a little out of it." And one of the agents immediately said, "Why?" I said, "Because I've been traveling for over 24 hours now." Apparently that was good enough but I think they are trying to look for things in people's behavior that may be off. And it's not like this is just a US thing. My last visit to the UK I was asked quite a few questions about why I was there, where I would be, what I'd do, etc. I've got a Hungarian residence permit and if I'm entering Schengen in Hungary they never ask me anything but if I come in through different place - Schipol most often, it's not unusual for them to ask me stuff about myself, what I do, etc. My last visit to Ukraine a few weeks ago, when I check into my hotel they made a copy of my passport information page and then had me find the stamp I'd gotten at the airport and they copied that. I know that's not the government guys but that was a new one for me. I'm used to giving passport info. for checking into a hotel but I've never seen them do that. Each place is different and to me it's all just a matter of degrees.
- pav3l 10y agoOne of my math professor (Canadian) once told us a story (~10 years ago) that the US border control asked him to "state and prove Rolle's theorem" after he had told them he was traveling to a math conference. Apparently he answered "it's something to do with the mean value theorem, right?" and that was good enough.
- mwidell 10y agoI've also been asked for my occupation, and then my business card, and then my website – which they actually started browsing as I was standing there in the passport control. This was back in 2009.
- dragony4 10y agoI am not surprised by this. When I was at Newark the conversation with immigration guy was something like this: Him: What do you do? Me: I am an entepreneur. Him: Haha, ... we are all entepreneurs, now really, what do you do? Me: Websites Him: I've heard there is a Sillicone Valley in Russia and they want to take over that ours. Me: Um, okay. (I am from Czech Republic)
- hiharryhere 10y agoI think lots of people on this thread are missing the point. This won't necessarily detect a determined spy who's done their homework. It's not meant to. It's a quick and effective sanity check to make sure that a person hasn't fudged their visa credentials and they're well in their rights to ask and exercise their discretion. They've been doing it for years. I doubt a perfect answer to their trivia question is required. If it's in your field you'll be able to say something halfway intelligent in response, if you've lied on your visa it will become obvious pretty quickly. Outrage about confiscating phones and demanding passwords is justified. This, on the other hand, seems pretty reasonable.
- djhworld 10y agoI always found the cold, hard manner of border agents in the US quite off putting in general. Last year I was fortunate enough to attend AWS Re:Invent, standing in the queue at McCarran airport, I saw the guard laughing and joking with the people in front of me so I thought ah, maybe they're all not like this! As soon as it came to me the guy completely changed, he went cold, he spent the most amount of time asking why I'd ticked "business" on my customs form, as I didn't know what to tick, then proceeded to ask me what conference I was going to and what it was about and why I was attending. I know that's his job and he's just making sure everything lines up, but it just felt unwelcoming.
- stoolpigeon 10y agoI've had the same experience for the most part with a few exceptions. It's unfortunate and I'm not sure about the root cause but you are right. Of course I've met a lot of immigration/customs officials from around the world who are also pretty intimidating. I wonder if the job attracts people who enjoy having this kind of power over people. Or if maybe after getting the job, they are changed by knowing that they can very easily, on a whim, make life very hard for someone. What bothers me more than the US immigration and customs people are the security employees - TSA. I've seen many more of them be well past cold. They are often rude. I've seen them yelling at visitors to the US who are just trying to get through security and obviously don't speak English well. The kicker is when the TSA person doesn't speak proper English themselves and are obviously not very well educated.
- Kephael 10y agoTSA agents are on par with retail store employees in terms of hiring standards. The Customs and Border Patrol agents are armed law enforcement officers and are held to far greater hiring standards.
- taway_1212 10y agoI've read somewhere that, if border controls were abolished, about a billion people from all across the world would move to the US. I'm guessing that, since people already want to come to US pretty badly, being welcoming is not a high priority for border personnel.
- reledi 10y agoA few days ago a Nigerian software engineer was asked to balance a BST at JFK airport: https://twitter.com/cyberomin/status/835888786462625792 https://twitter.com/cyberomin/status/835888786462625792
- rezashirazian 10y agoI think he was asked to write a function that will return true if the tree is balanced, not to actually balances it, which in my opinion is an exponentially easier question.
- curryhowardiso 10y agoHey y'all, I'm the person they mentioned in the article. Because this is a fairly technical forum (and some people were asking about language specifics or runtime characteristics) I'll let you in on the question even though I left it out of the journalist interviews - hopefully this information will help you make sense of the article/interaction for yourself: Write a Python program to take two numbers as input and if the sun is bigger than 100, output "this is a large number" but if it is less than 100 output the sum of the numbers. Lol!
- GedByrne 10y agoCould he have just been getting some sneaky help with his college homework?
- aptwebapps 10y agoThat's a lot better than balancing a BST like that other guy got.
- ZoeZoeBee 10y agoWhat were you denied entry for previously?
- joshjje 10y agoFizz Buzz
- curryhowardiso 10y agoSorry? I wasn't denied entry ever... Ahh the news.com.au article isn't worded very clearly: the person in front of me was denied entry (not me!)
- zepolen 10y agoIf the sun is bigger than 100 what?
- curryhowardiso 10y agoSum* Sorry!
- deleted 10y ago[deleted]
- jondubois 10y agoI just don't believe this. It's fake news. This line made it clear to me: "He said the officer appeared to be mid to senior level, and there’s no chance the conversation would have been overheard by anyone else in line." So basically there is no one who can corroborate with his story. This trash should not be allowed into any publication which calls itself 'news'. I'm surprised that people actually believe that stuff by default. In this new world, the default should be to distrust the media and that line I quoted above gives a very good reason to distrust it.
- curryhowardiso 10y agoI was the person in the story and I'm pretty sure this person could! https://twitter.com/cyberomin/status/835888786462625792 https://twitter.com/cyberomin/status/835888786462625792
- jondubois 10y agoI don't believe that either. It's such a specific question - I don't know if even Facebook or Google would ask such a question in their interviews. This guy you just linked to has posted 11K tweets in the past; obviously an attention/status seeker. Also his follow-up tweet gave it away: "So @Twitter I can now get the blue tick, yes?" He almost didn't get any retweets before his 5 minutes of fame. Wow people on HN can be so gullible.
- curryhowardiso 10y agoOut of curiosity, what threshold of evidence would you accept that I provide to verify that I was indeed asked to write code at the US border? I'm almost certainly not going to provide it, but I'm still curious if you're willing to elaborate.
- vacri 10y agoPassing through customs, there's rarely anyone else around to corroborate if you're taken aside.
- HappyTypist 10y agoI'm in the US right now. Upon arriving in SFO (from Sydney) on a holiday (ESTA), I was asked the following non-standard questions: "So you're a software engineer? What is your most proficient language?" Response: "Javascript" "What does the atob function do?" I was quite taken back and asked to repeat, and the CBP agent spelled out "a t o b". I answered something to do with base64 decoding and was let through
- ubersoldat2k7 10y agoHaha! Shit! The only time I've used atob in 20 years of doing JS was to read the ProtectionHeader of a SmoothStreaming manifest file recently. I'll bet little to none JS programmers know specifically what it does or if it even exists.
- chvid 10y agoDon't blame this on Trump; it goes on all over the world. If the border police officer for any reason decides that you are suspicious then they will toy with you as they please. That includes asking arbitrary questions under the threat they can send you back to home country for any or no reason. Plus they can fingerprint you and go thru all your travel goods including phone and laptop. As foreigner you have no rights standing at the border of the country you are entering. And the border police operates without the checks that a normal police force operates under. If you are a frequent traveller you better get used to being interrogated; answer short and precise without using any trigger words.
- js8 10y agoThis reminds me of a George Gamow's story (which can be an urban legend attributed to him) in Soviet Russia, I think when he was trying to flee. Allegedly, he was detained by some local warrior group in Caucasus(?). The local chieftain didn't believe he was a theoretical physicist, so he asked him to derive the n-th error term of the Taylor expansion. Fortunately, he was able to do that and save his life! I take it as one of those lessons of usefulness of mathematics in daily life. :-)
- BugsJustFindMe 10y ago“‘I’ve got a problem, I’m trying to write a computer program, can you help me?’” "My software consulting rate is normally $400/hr, plus an initial startup fee, but I'm not authorized to work in your country, so, no."
- eps 10y agoThe fact that this has started happenning in parallel with H-1B crackdown is not a coincedence. Someone somewhere issued a note that too many fake programmers are slipping in, so that's the result.
- lordnacho 10y agoI don't like the nervous atmosphere they make at the US border. It's the only country apart from Cuba where you get the feeling they might deny me entry for no reason. And it's the only country that I personally know people have been denied entry for no reason. It's the way the questions come out, like a movie. The words come out slowly while the guy looks for something in my eyes. I haven't been grilled on professional questions, but I wonder what I should say I do. Programmer or Trader are both legit. If I say programmer, I might get a technical question. If I say trader, maybe I just have give him a random stock tip.
- seesomesense 10y agoA investment banker I know ( private equity, with a well know firm that has a AUM of $340 billion ) was asked : "Why do you you hate the USA ?" when he last flew to the US.
- karg 10y agoWhy not just strap them on a lie detector and ask if they have any intention to do anything illegal?