TFW you go six for six technical questions in a job interview

>TFW you go six for six technical questions in a job interview

We're all gonna make it, lads. Anyone else had any career success lately?

The technical questions don't really matter. What they are looking for is cultural fit. "Would this person be someone I would want to go to a bar with?" The technical questions are just there as filler while they judge your personality.

confirmed for NEET.

... No, that's the initial screen. Besides, I'm not a fucking asspie. I know how to talk to people without stammering and sperging out all over myself.

>Anyone else had any career success lately?
I literally got fired today. The exit interview seemed to imply I hadn't even done anything wrong; the new management just wanted to fire someone so they got rid of the trainee new guy who was earning half what anyone else was getting.

By the way, is there anyone here who lives in North-West England who is looking for a Pajeet-tier entry-level pleb? I'm promise I'm fun and not autistic, and I have lots of experience replacing hard drives and creating virtual machines for software testing.

Promoted to first managerial role, after being a developer for so long.

So true.
One financial company told me they hire based on "If I was stuck in an airport over night with this person, would I be wanting to gouge their/my eyes out with a spoon?"

I have always found that after you get your first entry level job, its all being recommended by a friend to move or private job offers.

Like always do the best you can. Even if the company you're at currently doesn't recognize you for it, someone who is leaving to another company will, and will try bring you with them

>Pajeet-tier
There's no way you're this bad.

what were the questions?

got my first remote job a month or so ago. Feels good man.

They were relatively simple. I just came off a pretty bad interview with Google, so I was honestly expecting to not do so well again.

1) Given an unsorted array of numbers 1-n, find the one that has been replaced with zero.
1b) What if the array is immutable?

2) Given a linked list of characters, print them in reverse.
2a) What if you can't use an additional data structures

Grats bro. Good luck in the future. Hopefully you're successful.

>replacing hard drives and creating virtual machines for software testing.
B-but that's trivial. What else do you know? It's like saying "I can install programs".

Company?
I've been trying to join Automattic. No success so far.

What is "six for six"?

This.

Most jobs are taught when you Start working there. They just want to know you understand the basics, you're capable of learning and you're not a faggot

They asked me six questions and I got them all right. There were really only two questions, but the way they them turned it into six.

Basically they asked me for an immediate, brute force solution, then they put a restriction on it and then restricted it further.

1) Loop through the array searching for a zero value?
1b) Doesn't really matter

2) Recursively go through the list and search for the tail node, then print the characters from bottom up
2a) Above works with this

this is what I thought as well, but both seem too easy.

I think I am misunderstanding OP's descriptions of the questions

What type of experience do you need for a web dev job? I've done freelance stuff for years but like 80% of it is just simple websites or utilities. Nothing is really impressive. But I've been running websites in one form or another for 10 years since I was kid.

I have a good light understanding of everything from dicking around so much. I don't have a CS degree but I'm not too worried about technical questions with some time to study.

I'm tired of managing clients for less money than I'd make at a real job but I'm not sure how I would go about selling myself. Thinking about making a resume feels me with inadequacy.

First one isn't sorted, so if you find a zero, how do you know which number is zero?

For the second one, I gave an answer of reverse it and run it, then push it to a stack and pop it and finally the recursive answer.

The interviewer kept telling me not to think about it too much at first and just say what immediately came to mind. Said it was more important for him to get my thought process than for me to find the optimal solution.

>First one isn't sorted, so if you find a zero, how do you know which number is zero?
can you explain this?

if the array were sorted, the answer would be trivial, since the zero would always be at either the very beginning or very end, no?

pretty sure op means that you have a shuffled, consecutive set of numbers 1 through N and one of them got replace with a 0 and you have to figure out which one it was. An obvious first solution is to sort the array, which is why the second part is about the array being immutable.

I think he means if you have something like 01235 4 was the number that was replaced with 0.

ohhhhhhh
that is a much better explanation.

thanks, anons.

Sorry m8. Guess I'm not as smart as I thought I was if I couldn't explain the problem correctly.

so how do you solve it

Do they only ask quiz questions for young and inexperienced employees?
Do they still do that if you have 10 years of experience?

missing_no = sum({1,2,3,...,n}) - sum(given_array) works for immutable

for the second question, are you given a pointer/reference to the last element or only the first? know the size ahead of time? singly linked or doubly?

What's your solution to #1 (immutable version)? Best I can get is O(n log n):
> loop over the array, counting the number of items where a[i] < N / 2 (and a[i] != 0) and the number where a[i] >= N / 2
> compare both counts to N / 2, one will be short by 1 because a number in that half of the array was replaced with 0
> repeat, binary search-style, until you find the exact replaced value

I recently got laid off along with automation and frontend at our small shop so they could hire a data science guy. I was a glorified mvc repair monkey, so when I landed a corporate job making 20k more worth better benefits all around {pension and 401k matching, fuck yeah} doing machine learning, I am one happy mother fucker.

We may have more meetings and not drink like madmen, but it's otherwise better in every way.

Second one, walk recursively down the list and print each char on the way back up. Basically a post-order traversal, treating the list as a trivial case of a tree.

>sum({1,2,3,...,n})
user...
n(n+1) / 2

Not him but I'd do it like.
Sort it
Iterate from start to end comparing index i to arr[i+1] if i is greater than arr[i+1] then arr[i+1] is the zero.

Singly linked, unknown total size, given the reference to the first element.

thanks gcc -O3

Quick question. I've taken an AI class and a few other related subjects but can one self teach ML and get a good job? I'm a CS major and have been working through a ML book recently as well as trying to use it to tackle some projects. I was wondering if I keep on learning and get some projects going if that's enough for me to apply to machine learning/data science jobs. It's really interesting to me but my university doesn't offer many opportunities to take a class structured around it. Thanks.

its a mom and pop business with about 50 or so people. Too fear to reveal.

You're overthinking it m8.

Since the array consists of n DISTINCT elements from 1-n, you know the sum of all numbers from 1-n is (n(n-1))/2. So if you run through the entire thing and add them together, then you've got some number

(n(n-1))/2 - m = k

where m is the total of the edited array, and k is the number that's been changed from its original value to zero.

Thank you sir.

>So if you run through the entire thing and add them together
This is still O(n), though.
I am wondering if you can get it faster.

Obviously the "unaltered sum" part is is still fine using .5n(n+1), O(1)

Ah, sorry. I misread your post. I'd say I'm tired, but I was just lazy and didn't fucking read it.

I think your algorithm isn't O(n log(n)) for one reason. You say you loop over the entire thing. Plus, even when you do find the correct number, you can't necessarily tell which one it will be, unless I'm misreading your algorithm.

Binary search style solutions only work on sorted lists.

I've a technical interview coming up with the CRA. I don't really know what to expect as the position is pretty vague but labeled as IT development. It's an apprenticeship but still pays better than what I make. I made it past the initial assessment which was some standardized English competency/behavioral questions and the rest of the applicants in the room were pajeets and a couple of asian girls, so the odds are against me. Interview's in 3 weeks and I'm going through cracking the coding interview and just general interview questions. I remember fortran or cobalt being mentioned by one of the exam facilitators. Any advice on what else I should be doing? Books to read? I'm skeptical but still would like to give it my best.

I'm not sure you could find a solution without looking at all the numbers at least once in this case.

>I am wondering if you can get it faster.
I am very confident you can't do better than O(n). The list is unsorted, so you at least need to inspect every element.

Call the removed element `x`. For any `k`, you can scan the list (in O(N) time) and discover whether x < k or x >= k. Now do the following:
> is x < or >= N / 2? (suppose it's is x < or >= N / 4? (suppose it's >=, meaning N / 4 is x < or >= N * 3 / 8? (suppose it's

Depends. In my case they wanted to grow someone into the position. I came showing my bona fide with analysis but no direct experience. But they wanted someone with those chops and a background in Java, even though I've been thrown into the deep end of Scala.

Best thing you can do is get a project going. Make a bot, play with tensor flow or CTNK or that new amazon engine.

for the mutable case I would suggest

sort array ( hopefully

>The list is unsorted
Curious, how do you think you could make it faster than O(n) if the list was sorted? I can't think of any additional information you could glean from having it sorted that would lead to constant time complexity.

>though now that I think about it, I believe the actual best case would be to integrate this check into the sorting algorithm somewhere, to get the entire thing in nlogn
It's O(n log n) regardless. O(n log n) + O(n) is still O(n log n), that's how big-O works in general. So there's no need for binary search, you can do a linear scan and get the same asymptotic run time.

>sort array ( hopefully

Binary search gets it to O(log N). Basically this user's algorithm, except without the magical sublinear sorting step: O(1) seems outright impossible, since it requires obtaining O(log N) bits of information about the input in O(1) time. (The removed number is in the range 1..N, so it's log2(N) bits long.)

>O(log n) binary search
derp, ya I wasn't thinking.

>tfw my company just asked me to solve real world problems of theirs because they're not faggots

POO

mine did too, a handful of easy syntax question + 'you have an hour, write this simple program and send us your code' (not in person, but this + a phone interview about past projects was all i needed)

But to be fair, op's questions are basically 'did you pay attention even once in your whole cs degree' tier and should be easily solvable by anyone.

Nice, that gives me some hope. I've been doing just that, playing around with tensorflow and what not. It'd be awesome if I could somehow make this type of stuff my career.

>Anyone else had any career success lately?
Well, as a NEET I masturbated 6 times today. That sort of counts.

What countries your bros work in?

I'm USA. Atlanta has a decent market. Though we've got our share of wannabe unicorns.