Nah, when you do that, Murphy's law says that the interviewer will be the only person in the world working on extending nonstandard analysis to spectral hypergraph theory, and my attempt to snow them will reveal that I only have surface level understanding of the jargon I just emitted.
That or they're the super egotistical/arrogant type but too dumb to know you know more than them and assume somehow you're the person who don't know what they're talking about
I once was interviewing for an interesting job and the topic was general knowledge of a system made of A, B and C (all were similar). The interviewer did not know much but insisted on some very deep details about B. I told him more than was available in the docs already and at some point I said I would need to peek in the code to say more.
He told that this was too difficult for me because only people who were part of the team who designed that would understand.
I told him that I wrote almost by myself the A part so it won't be too difficult to catch up with B.
I did not get the job (ultimately a happy ending) and was told that I did not know enough on A (the part I wrote).
I am joking but not really, basically it's my belief that any place asking for 10 years of a 5 years old technology is going to be really sensitive about anyone with an "attitude"
fun fact, I once interviewed at a place in which the tech lead interviewing me had confused the terms pass by reference and pass by value - that is to say he understood that in JavaScript objects were passed by reference and what that meant on the practical effects of assigning object a to b, but he thought the technical term for this was pass by value and the technical term for things that were passed by value was pass by reference (so according to him strings were passed by reference and objects were passed by value) and no explanation on what a reference was and how pass by reference works and why it made sense to call it pass by reference could penetrate.
I just went down the rabbit hole of reading this post and the entire thread. As someone who has been looking for a junior job, it's probably the most depressing thing I've ever read. I've been on the market for over 6 months, I've sent countless resumes out and tried various techniques, but I'm not even getting a nibble.
I guess technically it's passed the reference to the string right, so if I say a = "stringA" there is a reference to "stringA" and that is assigned to a if I then say a = "stringAA" there is another reference created for "stringAA" and assigned to a, while "stringA" is sitting around somewhere waiting to be garbage collected in a few milliseconds - that's way complicated to think about and not sure if I haven't messed it up.
Easier to just say pass by value and forget about it. OR make all your variables consts and then it don't matter.
No, thats not correct. Value and reference assignment behave the same way for = (well, reference is hiding the fact that it’s not the literal string/object but a reference to it, a number is just the number).
Where it matters is in passing arguments to a function call. If you pass 42, it’s not mutable so incrementing, or doing anything, will not modify the original variable you passed-in. For a reference, using = will assign a new value (not change the original) but modifying the referenced object like, say a.b = 5 WILL change the original object.
It’s not really “pass by reference” that a C/C++ developer would understand but it seems to be the term that has stuck.
>= (well, reference is hiding the fact that it’s not the literal string/object but a reference to it, a number is just the number).
>For a reference, using = will assign a new value (not change the original)
what I wrote was regarding only strings, so I'm not understanding - it seems you are saying the same thing I said? But maybe I'm wrong about how the actual strings are stored.
Sorry to get a bit nerdy here, but in JS, neither pass by value nor pass by reference make sense as it’s not defined by the spec and much less followed by the implementations. Strings can be pointers to buffers or ropes, numbers can be values (NaN-boxed or otherwise) or pointers depending on a number of conditions, it all depends. However, from what’s observable in the language, all variables are pass by value. There’s no way to pass anything at all by reference, primitive or not, i.e. you can modify a field of an object you were passed but you can’t change the object.
So the naming is super confusing in these cases and the best way to get out of it is say "the references are passed by value", but... technically he was right. In JS everything's passed by value. It doesn't matter that those values are references. Pass by ref would mean that "function foo(a) {a='123'}; b=''; foo(b)" would change the value of `b`.
Every popular language which allows pass-by-reference makes those places very explicit (like ref in c++ and c#)
>but... technically he was right. In JS everything's passed by value. It doesn't matter that those values are references.
yes, technically I know this but even so he was technically not right because he still said there was pass by reference and pass by value in JavaScript, it's just that the description he had of what happens in pass by value is what is normally described as "pass by reference" and the description he had of what happens in pass by reference is what is normally described as "pass by value".
I think we can agree that given that he used both terms and mixed up their meanings that he was not "technically right"
on edit: meaning if he had said "we pass everything by value in JS but some values are references, what happens then?" he would be right, but when he said we pass objects by value and primitives by reference - what do these two terms mean and then he accepted the description of what happens in an object when passing the reference as being correct but insisted that was called pass by value, and he accepted that the description of what happened with a variable when it has a string assigned and then that variable is assigned to another variable and then the first variable is changed was correct including the ability to change the value of variable A and not have the value of variable B changed thereby but insisted that this process is called pass by reference, I intuited through this conversation that he was unfortunately not "technically correct"
Well that's just it. Too many interviewers use it as a platform to flex how awesome they are. The proper response is at the end to ask a few probing questions of where they get to apply such skills day to day.
Unrelated, have you perhaps done anything with nonstandard analysis on graphs (or in spectral hypergraph theory -- most uses of NSA on graphs require infinite graphs, how does that work when the spectrum might not be defined?)?
Hahaha! I only crammed some dense jargon into a sentence to give the air of expertise... it's a bit of a trick, finding a combination of math terms that doesn't refer to an actual field of study.
It's been awhile since I've looked at NSA on graphs, but it's an interesting field of study. For something of a taste, an alternative proof of Kőnig's lemma might look like:
- Start with a locally finite, connected, infinite graph G.
- Choose any nonstandard extension G* of G.
- By the transfer principle (basically just logical compactness), there exist hyperpaths [0] of unbounded (hypernatural) length in G*. Pick one, P*.
- Restricting P* to G you obtain some path P, which is the infinite path you're looking for.
I settled into industry instead, but that's the sort of thing I'd like to study if I ever go back for a PhD, hence the interest in those sorts of ideas applying to spectral theory.
[0] The "transfer" of a path isn't actually necessarily a connected path in the usual sense, but it's indexed by the hypernaturals, and each well-ordered countable segment is connected. I'm skipping the entire intro that makes those operations make sense.
Well, you did nerdsnipe me too :) I haven't looked at this in awhile, and my curiosity is re-ignited.
The most basic style of proof in a lot of nonstandard analysis is (1) lift your problem to a nonstandard space, (2) prove something interesting in that space, (3) hopefully project something interesting back down to the problem you actually care about.
E.g., in nonstandard real analysis you can look at a real-valued function like f(x) = x^2, pick any epsilon z, and compute the hyperreal analogue (f(x+z)-f(x))/z = 2x + z. This is within some infinitesimal of 2x, so you use some machinery you've built up to conclude the derivative of the real-valued function is 2x.
The graph lemma above had a similar flow. Create G*, find something interesting, project it back down to G, finish the proof.
That's certainly not the only proof style. Nonstandard topology combines basically all the normal compaction theorems into one, for example, and that's a bit more intricate.
Even such crude techniques can bear fruit quickly though. Menger's theorem was proven in the early 1900s, and only extended to infinite graphs in the late 1900s. That 3-step proof process with nonstandard graphs makes it a bog-standard freshman exercise for locally finite infinite graphs, and only a bit more involved for the full generality originally proven by Erdos and friends.
I don't have any deep insights beyond that. The Springer GTM series has a nice intro to nonstandard analysis (not actually graduate-level IMO, a mid/advanced undergrad could use it, which is a nice level for that sort of book), building it up in a way that you could probably work with nonstandard extensions of other infinite structures (like graphs) without needing many/any other resources, especially if you've done much with building models of other theories via set structures.
Murphy's law is about things going wrong. But nothing can go wrong when encountering someone who knows more about something than you. You only stand to gain.