Are You Smarter Than Me? LinkedIn JavaScript Quiz Interview Questions

  Рет қаралды 71,140

Web Dev Simplified

Web Dev Simplified

Күн бұрын

The first 1000 people to use the link will get a free trial of Skillshare Premium Membership: skl.sh/webdevsimplified12201
In this video I decided to tackle the LinkedIn JavaScript quiz. It was quite a bit trickier than I expected as there were tons of really obscure questions. Luckily there were also some really easy questions that helped balance it out. Overall I think I did pretty good, but I am interested to hear more about the questions I got wrong from you down in the comments.
🌎 Find Me Here:
My Blog: blog.webdevsimplified.com
My Courses: courses.webdevsimplified.com
Patreon: / webdevsimplified
Twitter: / devsimplified
Discord: / discord
GitHub: github.com/WebDevSimplified
CodePen: codepen.io/WebDevSimplified
⏱️ Timestamps:
00:00 - Introduction
02:01 - Question 1
03:30 - Question 2
03:46 - Question 3
04:02 - Question 4
04:39 - Question 5
05:19 - Question 6
05:46 - Question 7
06:55 - Question 8
07:22 - Question 9
07:44 - Question 10
09:03 - Question 11
09:53 - Question 12
10:33 - Question 13
11:05 - Question 14
11:42 - Question 15
12:36 - Outro
#LinkedIn #WDS #JavaScript
This video was sponsored by Skillshare

Пікірлер: 320
@WebDevSimplified
@WebDevSimplified 3 жыл бұрын
The first 1000 people to use the link will get a free trial of Skillshare Premium Membership: skl.sh/webdevsimplified12201
@NeoniumOxide
@NeoniumOxide 3 жыл бұрын
Oakey
@davidarogunre7251
@davidarogunre7251 3 жыл бұрын
Now way I am smarter than you. You are a walking wikipedia
@mirkosedda3196
@mirkosedda3196 3 жыл бұрын
One less available! Thanks a lot buddy, the javascript section is insane!! Defintly an happy christmas studying 🤣🤣😍🤑
@rosmalina
@rosmalina 3 жыл бұрын
Thanks a lot for this. I enjoy this video very much. Normally you're so prepared in your videos and xplain things in elegant confidence. now I get to see your hard thinking mimics (which was a pleasant :D) and then managed the top 5%. Despite all u seem so humble.
@agilkerimov
@agilkerimov 3 жыл бұрын
when you add an element into an array with an index greater than the length of the array, it adds empty elements before this. So when you execute a[100]=1, the array's length becomes 101
@Malvitima0
@Malvitima0 3 жыл бұрын
That's so fuck-up
@codevev
@codevev 3 жыл бұрын
@@Malvitima0 I so agree
@stevenedwards9262
@stevenedwards9262 3 жыл бұрын
Correct - it fills in all the elements in-between with "undefined" and will return 101 because of 0-indexing. This is definitely one of the ones WDE got wrong, lol
@justintaddei
@justintaddei 3 жыл бұрын
@@Malvitima0 There's a very good reason for that. Imagine if the length in the example actually was 4. If you tried to loop over an array, `for (let i=0; i
@ruynobrega6918
@ruynobrega6918 3 жыл бұрын
@Malvitima0 Arrays on not-so-high level languages (like C) are continuous strips of memory, which has an implicit order (from lowest memory address number to highest memory address number). Higher level languages (like JS) are not obliged but they do use similar concepts for their lists/arrays, which is a group of objects in an ordered, indexed manner. If you think about it, if you wanted the result to be 4, you would much rather be expected to use maps. So, if you assign the 100th element of the "memory strip", it is logical that this "strip" must also contains the 99th, 98th, 97th ... elements. Hope it helps!
@IkraamDev
@IkraamDev 3 жыл бұрын
This is a perfect test to TEST how fast you can Google!
@adarshkotali
@adarshkotali 3 жыл бұрын
true😂
@javascript2409
@javascript2409 3 жыл бұрын
I run code and see what is answer ( fewquestion )
@njpromethium
@njpromethium 3 жыл бұрын
@@javascript2409 that's exactly what you're not supposed to do...
@xxxxdddddss
@xxxxdddddss 3 жыл бұрын
@@njpromethium atleast he will learn something this way because this stupid test wont show you where youve made a mistake
@priyanshubhardwaj2158
@priyanshubhardwaj2158 3 жыл бұрын
@@javascript2409 That's a nice idea. Never thought about it though.
@sergten
@sergten 3 жыл бұрын
The array length is 101, it always picks the highest one and returns undefined for the uninitialized indices: > let a = [1, 2, 3] undefined > a[100]=100 100 > a.length 101 > a[88] undefined
@Technoph1le
@Technoph1le 2 жыл бұрын
That's is CRAZY!!!
@PortEXE
@PortEXE 3 жыл бұрын
Awesome video! The answer to the first one is "immediately". There was no HTTP request in the code. I think you may have overthought that one and took into account the way that the JavaScript is actually loaded into the interpreter via the browser.
@WebDevSimplified
@WebDevSimplified 3 жыл бұрын
I really did. That one really tripped me up. Luckily the rest of the test was much more straightforward.
@josephcagle
@josephcagle 3 жыл бұрын
I think they were hoping to trip up people who might think that the querySelector() sends an HTTP request. Kinda weird and ambiguous IMO, though
@Victor_Marius
@Victor_Marius 3 жыл бұрын
@@josephcagle if that code would be in the head and executed in the head, that querySelector call would return null or an error, not sure since I learned my lesson not to query the DOM before it is loaded.
@williamcraigz
@williamcraigz 3 жыл бұрын
Q:12's correct answer is 1. It is about closures. When a variable of a function does not exist, it will look for it at its outer lexical environment. In other words, variables wont be looked at the outer place where the function was invoked, but where it was declared. Using 'var' or 'let' will have no difference here, the result will be the same.
@Shivey73
@Shivey73 2 жыл бұрын
that's correct but for the sake of completeness, if the second keyword var was omitted, v's value would have been updated and the result would be 2. using var creates an internally scope variable v in function f2. var or let would have made no difference.
@user-uf8yn8xm7h
@user-uf8yn8xm7h Жыл бұрын
@@Shivey73 i dont think it will. var is function scoped in f2 so it will stay there. f1 doesn't have var v so it will look outside ( in this case the global scope). so the answer is 1
@Shivey73
@Shivey73 Жыл бұрын
@@user-uf8yn8xm7h maybe my explanation was not clear enough. If in f2 you state v=2 instead of var v=2, the global var which was 1 would be updated to 2 and the answer would become 2.
@FenrirTheMenace
@FenrirTheMenace 9 ай бұрын
For those who come later and still don't understand: just compile it. You'll see what they say is true. Don't be like me, who had to question this.
@jburggraf
@jburggraf 3 жыл бұрын
I took this test back in the spring and didn't get in the percentile needed to pass. I have used javascript on and off for years, but kind of just learned what I needed to know in order to complete whatever task I was working on. Last month I saw Kyle's javascript simplified course and decided to give it a shot. I took the linked in quiz again after completing the course and got top a 5% score. This is not any kind of paid endorsement :) but it is definitely a recommendation to consider the course if you need to strengthen your javascript skills.
@WebDevSimplified
@WebDevSimplified 3 жыл бұрын
That is awesome Jim! I am so glad that the course was able to teach you everything you needed to know in order to ace this quiz. I also hope it taught you what you need in order to build any project you can think of.
@hendrikhausen1058
@hendrikhausen1058 3 жыл бұрын
It's great how relaxed you are in your videos. Also, amazing that you get straight to the point without talking about nonsense for minutes. Keep up the good work!
@ibtsamnoman2415
@ibtsamnoman2415 3 жыл бұрын
10:25 It would have redefined global var if we didn't use var keyword with it As var is scoped to function not global, f1 will log the global var v with value 1
@julienrousseau3581
@julienrousseau3581 3 жыл бұрын
That s also what I was thinking
@ibtsamnoman2415
@ibtsamnoman2415 3 жыл бұрын
@@NachoDLF Yes it would be the same result.
@lurkinginthedark6498
@lurkinginthedark6498 3 жыл бұрын
This one actually a little bit tricky, we knew that var's scope could be confusing but in this case it's definitely 1 because the global var
@devingray1761
@devingray1761 3 жыл бұрын
Exactly. Var can be hoisted but not outside of block scope.
@xBZZZZyt
@xBZZZZyt 3 жыл бұрын
@@lurkinginthedark6498 "var" is function scoped
@batchrocketproject4720
@batchrocketproject4720 3 жыл бұрын
Hi Kyle, I love your videos, and you're definitely smarter than me!. I rarely comment but feel a correction is in order as it's fundamental: Q12 (on var and v=1, v=2). The var inside f2 is not the same as the global var! (it would be only if var was absent). Scope is defined by the block so declaring (with var, or let for that matter) v inside function f2, makes it invisible outside of that function. The declaration inside f2 does not alter the global value of V. The reference to V in f1 can only see the globally-declared V and so the answer is 1 not 2. (I probably haven't explained it as well as you could but the results never lie, try it!). Thanks for your efforts and keep them up!
@diegocastro7434
@diegocastro7434 3 жыл бұрын
Hey man, I just wanted to thank you for making all of these awesome videos. I (computer science grad) started watching your css/html videos and have been following all your projects ever since. Keep up the great work!
@noumanmalik960
@noumanmalik960 3 жыл бұрын
The most intense video I watched on KZfaq. Congratulations Kyle!
@codingwithkenny6492
@codingwithkenny6492 3 жыл бұрын
You're an amazing teacher Kyle! Your videos are concise, straightforward, and fairly easy to understand even for a beginner like me. I'm only 14, but I'm trying to make the most of my quarantine so that's why I started coding since last year. Watching your videos helps me a lot when I get stuck on a project!
@carminetambascia6355
@carminetambascia6355 2 жыл бұрын
keep doing. If you learn JS at 14, the time you will be 16 or 18, I am sure you would have built you own startup. Here, 36, that still is reasoning about those question. Of course I got other software language
@manny8156
@manny8156 3 жыл бұрын
The array length was 101
@noumanmalik960
@noumanmalik960 3 жыл бұрын
actually that made me feel better that even Kyle can make mistakes lol
@gametony947
@gametony947 3 жыл бұрын
Was about to point that out XD
@ilverin.matriam
@ilverin.matriam 3 жыл бұрын
Glad to know I wasn't the only one thinking this.
@TheCodingOdyssey
@TheCodingOdyssey 3 жыл бұрын
I was thinking the same, for the array length to be 4 the element at index 100 should be just after the third element, not possible.
@tommysingh7546
@tommysingh7546 3 жыл бұрын
sparse arrays**
@diegopalacios68
@diegopalacios68 2 жыл бұрын
In question 12 it will log 1. Since during compilation, the value if v inside f1 will reference the variable in either its outer or local lexical scopes. v2 has been declared inside a different lexical scope, thus it doesn't re-declare var in the global scope. In other words, the v variable declared in the outer scope becomes a closure of f1 anonymous function, and is going to carry this "backpack" wherever it gets called.
@user-uf8yn8xm7h
@user-uf8yn8xm7h Жыл бұрын
Q1. it will show immediately since it is loaded directly on call stack. the setTimeout is a macrotask so it will execute after call stack is free
@broccool2300
@broccool2300 3 жыл бұрын
I failed the JS test even though I use it daily and passed the C# and I hardly know C# and almost never use it. IMO those are some tricky questions that you will almost never run into and if you do you can google your way to the right solution to get the job done. Also, it is best not to try so hard to remember everything and develop a mind that can figure out how to solve problems instead of remembering everything someone else taught you.
@kisankumavat8387
@kisankumavat8387 3 жыл бұрын
I gave this test yesterday and got 5% but never thought you will give this test. Happy to see you there :)
@semlimi200
@semlimi200 3 жыл бұрын
Wow what an awesome helpful video! Thanks for posting. The suspense had me biting my nails lol
@SladeHxH
@SladeHxH 3 жыл бұрын
thanks men I really enjoyed this quiz with you hope you do it again and again !! I like it bro
@piotrwiniarski3397
@piotrwiniarski3397 3 жыл бұрын
Great stuff, I really enjoy and appreciate your content. Regarding Question 12 about what value will function f1 will log to console. I know reason of that but I got it wrong anyway as I rushed through when I tried to solve it along with you when I was watching video. The trick here is that var is function scoped, however it is also as important that scope of function is declared based on where function is declared, not where it is executed and here we have both function declared in global scope. For example if we have: var i = 1; function f1() { f2(); var i = 2; function f2() { console.log(i) } } f1(); then we would get three scopes: - global scope ( var i =1, function f1) - function f1 scope (var i =2, function f2) - function f2 scope () Now when execution of f2 happen, it check if there is variable declaration for i , if not it would look up in closest/nearest outerscope that is f1 scope. Here js parser would find variable declaration for i with value of 2 assigned so it would use that value in scope of function 2. I believe it is similiar but not exactly same as closure concept, that would worked differently, but correct me if I am wrong
@Joshuahendrix
@Joshuahendrix 3 жыл бұрын
This was very informative thanks glad to hear your thoughts on the test
@Jason-mx8dl
@Jason-mx8dl 3 жыл бұрын
First question is ‘immediately’ - the callback queue won’t run until the stack is empty.
@appajidevotionalsongs
@appajidevotionalsongs 3 жыл бұрын
👌
@jumaelahmed9995
@jumaelahmed9995 3 жыл бұрын
Man! you're the best CSS dev & the smartest one.
@priyanshubhardwaj2158
@priyanshubhardwaj2158 3 жыл бұрын
Learned a lot. Please do take these type of assessments for Front-End as these will help newer devs like us to evolve. Cheers!
@sthefanocarvalho2823
@sthefanocarvalho2823 3 жыл бұрын
5% here too! But I answered some questions differently haha It'd be great if we could know which questions we got wrong :/ Thanks for the great content as usual :) You are an inspiration
@bofe7
@bofe7 3 жыл бұрын
Number 1 would run the code outside of setTimeout first even if you set 0ms as the argument, because it places the code inside the setTimeout function at the bottom of the execution stack. I liked this video, it shows that even people who know a lot don't know everything.
@strawhatrick
@strawhatrick 3 жыл бұрын
I took this test about a month ago and got top15%. You're good 😅
@konradhylton
@konradhylton Жыл бұрын
q1 - Immediately q4 is 101. Arrays are linear data structures. Which means data is arranged sequentially. So if there is an item at position 100, then index 0-99 must exist q12 - 1
@hydraglide69
@hydraglide69 2 жыл бұрын
I started learning JS in March and took this assessment last month. I did well, but I already have a better understanding of the language and can reason out my answers much better than I did at the time I took this. I had no idea what a generator function was (I've since watched your video on them) and I think I also got tripped up on the array question.
@DThompsonDev
@DThompsonDev 3 жыл бұрын
Love this! I did that quiz and got a top 5% of all the people that took this test! Very excited and curious to see what you get Kyle!
@sankaranarayanan7847
@sankaranarayanan7847 3 жыл бұрын
Congratulations
@paujoan401
@paujoan401 3 жыл бұрын
also got 5%, are we gettin lied or what?
@mantinez1
@mantinez1 3 жыл бұрын
@@paujoan401 mine says top 5% too haha, it's pretty sus, plus the total is like 750k people
@mac8911
@mac8911 3 жыл бұрын
@@paujoan401 I got top 5% also. I was actually shocked as I was unsure about many of my answers.
@DThompsonDev
@DThompsonDev 3 жыл бұрын
​@@mantinez1 YOU GET 5% and YOU GET 5%! lol It is based off of the number of people that have already taken the quiz. Honestly, it is a cool thing to do over coffee though.
@minnh2094
@minnh2094 3 жыл бұрын
Holy shit I was exactly waiting for this one!!
@deansprivatearchive
@deansprivatearchive 3 жыл бұрын
void is for a function that returns no value. If you use return, it does not return a value - no errors, just no value is returned. It is basically a precautionary thing or a thing that you'd do for stuff that returns a value that you don't want returned.
@purplealma
@purplealma 3 жыл бұрын
Thanks. I really like your videos, I learned a lot from you.
@chaudhary3394
@chaudhary3394 3 жыл бұрын
Awesome, interesting ❤️ , waiting for next upload as this.
@jeffreyjdesir
@jeffreyjdesir 3 жыл бұрын
That was fun! very basic, I wish JavaScriptSkillzQuiz could be a hashtag online.😊 I learned something new from question 8; get methods must have went over my head in the spaghettis curriculum of TS/JS but sure looks very sugary! Makes the class paradigm worth using more honestly.
@J90JAM
@J90JAM 2 жыл бұрын
Actually really enjoyed this video, do another 👌
@geremsadaimary7094
@geremsadaimary7094 3 жыл бұрын
Keep these coming Kyle
@Daniel_WR_Hart
@Daniel_WR_Hart 3 жыл бұрын
Question 13, at least in the console you don't have to use let/const/var to create a function, but it will be a property of the window object. This doesn't work in ES6 modules though.
@iben1195
@iben1195 3 жыл бұрын
I was thinking Q12 @ 10:00 would print 1. f1 prints the global variable v, f2 defines a new variable v, which is function scope, and this is different from the v logged in the f1 function.
@AwayWeGo747
@AwayWeGo747 3 жыл бұрын
Im a beginner and this was helpful to me. I struggle with knowing how much I actually know. I got most right as well.
@GaLaVrAmOv
@GaLaVrAmOv 3 жыл бұрын
In question 12 the answer is 1 because of the second assignment of v is actually a new initial variable of the function 'f2', which means that it doesn't change the global 'v' variable..
@cliffordowusuamponsah9532
@cliffordowusuamponsah9532 3 жыл бұрын
I took this test last month and got top 5%. Damn! I am good!!😎
@eitanwaxman1862
@eitanwaxman1862 Жыл бұрын
Happy to see I'm not the only one that was a bit stumped by the LinkedIn quiz. Much prefer real coding assessments like CodeSignal etc.
@incubated
@incubated 3 жыл бұрын
howdy. great work. the function would have logged 1. f1 closed over v global v, not the f2 local v. since f1 does not accept v as an input, f1 logs unchanged global v 1. var is still function scoped. let and const are block scoped, in addition, so they will need to be redeclared in loops, if statements, etc. if f2 said v = 2, f1 would log 2. this is an example of why shadowing can get confusing. you lose track of what scope the variable is in.
@candi2Love
@candi2Love 3 жыл бұрын
+1 for mentioning "shadowing" you must be old skool JS ✌
@aartiverse
@aartiverse Жыл бұрын
Q12) var v = 1; var f1 = function() { console.log(v); }; var f2 = function() { var v = 2; f1(); }; f2(); When the code is executed, the following happens: The variable v is declared in the global scope and assigned the value 1. The function f1 is defined, which logs the value of v to the console. Since v is not defined locally within f1, it references the global variable v. The function f2 is defined, which declares a new local variable v and assigns it the value 2. This local variable v shadows the global variable v within the scope of f2. Inside f2, the function f1 is invoked. When f1 is executed, it tries to log the value of v. Since v is not defined locally within f1, it looks for the variable in the outer scope, which is the global scope. Therefore, it accesses the value of the global variable v, which is 1. Therefore, the code will print 1 to the console. NOT 2.
@iancuvlad7368
@iancuvlad7368 3 жыл бұрын
3:54 1 is PHP, 2 is Haskell, 3 is Javascript
@hansmuds6018
@hansmuds6018 3 жыл бұрын
first isn't php
@andriiauziak1178
@andriiauziak1178 3 жыл бұрын
Kyle, thank you for this video. And in 13th question there are two correct answers: discountPrice = function(price){...} without 'var' will also create function just fine. Looks like a mistake in this quiz.
@AvanaVana
@AvanaVana 2 жыл бұрын
This is true, and also true for assigning any variable without a variable keyword, but it will assign it to the global object and can overwrite global properties, like Window properties if the naming isn’t careful or secure. You can, however, do the same thing inside curly braces and protect the global scope. So, for example { discount = function(price) { return price * 0.85; }}. But obviously you would also have to use the function within the same block scope too, then. Though strangely when I try this in devtools console, I can still call the function after closing the braces and hitting enter, and it’s also not on the window object, unlike if you were to do it without the outside braces…
@Wreighn
@Wreighn 3 жыл бұрын
I got all of them right except 11. That was the first time I've heard of void in js.
@cedriccholley950
@cedriccholley950 3 жыл бұрын
4. Answer is 101 12. Answer is 1 because v === 2 only inside f2 it would have overwrite the "ouside" v without the var keyword 13. I agree with you, but answer number 2 could work as well (it is not a good practice to add variable to the gloabal object but this is not a crime either) 14. I'm not sure what the problem is expect the result is very predictable
@sudamdissanayake6620
@sudamdissanayake6620 3 жыл бұрын
I think the answer to the first question should be immediately. Timeout functions and other promise calls and what not will not be executed till the global thread of execution is done. Then only javascript will look for stuff in the micro task queue and callback queue. In this case setTimeout will always run last. Even if you have 1000 console.logs after that. Watch Javascript hardparts by will sentance. (Frontend masters)
@anand_dudi
@anand_dudi Жыл бұрын
thanks for this kyle you are great
@amlan715
@amlan715 3 жыл бұрын
Question number 12 will return you a value of 1 because f1 forms a closure with the global variables v=1 so when you invoke f1 inside f2 it doesn't really care about the local v=2 unless you pass it as an argument.
@stevenedwards8353
@stevenedwards8353 2 жыл бұрын
I was delighted when you got the a[100] question wrong, not in a malicious way mind you, but because it makes you seem more human, lol. I was shouting the entire time "it just fills the in-between values with 'undefined'!", lol
@workflop4117
@workflop4117 3 жыл бұрын
In my opinion In number 12 since you are using var you are creating a new local variable inside the scope of the function f2 and you are not assining the number 2 to the v present in the global scope (window)... if the keyword var wasn't there it would have been 2... hope to help someone with that... by the way thanks for sharing :D
@venkatesh2788
@venkatesh2788 3 жыл бұрын
I didn't skip your video, Very interesting video
@avgSE81
@avgSE81 3 жыл бұрын
More videos like this one please!
@SirXtC
@SirXtC 3 жыл бұрын
oh gosh I got top 3% and I still don't know how to make a simple todo list xd -edit : I'm actually not kidding, I did get 3% but I'm still not able to make apps without following tutorials :/...
@aammssaamm
@aammssaamm 3 жыл бұрын
cause it's a totally useless app. Do something which makes sense to yourself.
@TheCodingOdyssey
@TheCodingOdyssey 3 жыл бұрын
ha ha you crack me up lol
@kervensjasmin1508
@kervensjasmin1508 3 жыл бұрын
Most apps are crud apps. Just write down some key points and practice doing it blind without a tutorial. Getting stuck is a part of the process. I believe you can do it!
@reactkindasus4677
@reactkindasus4677 3 жыл бұрын
Rust POGU
@j0gi
@j0gi 3 жыл бұрын
@@kervensjasmin1508 I thought I was just being overly reductive when I had that thought but it turns out I wasn't the only one lol.
@ToeShimmel
@ToeShimmel 2 жыл бұрын
I've tried some of these linked in tests. They seem to focus on very specific and not often used details / behaviours of the language. In my opinion, knowing those is not what makes you a skilled developer. But that's my opinion.
@adicide9070
@adicide9070 3 жыл бұрын
do them all dude. fun fun fun. gonna do em too.
@gvgvgvijayan
@gvgvgvijayan 3 жыл бұрын
WDS could you please put a new video on ES2017 and what feature love about that. Why I'm asking this is around 94% of websites and engines are compatible with ES2017 standard and very few people fairly explained about. As you're my best JS teacher I love to hear your talks about ES2017 feature.
@markshinkai598
@markshinkai598 3 жыл бұрын
Please do more videos like this
@abrarahmed7549
@abrarahmed7549 3 жыл бұрын
I already have that batch on js,css, and python
@arctan2
@arctan2 3 жыл бұрын
we need more, i mean a lot
@sardorjumanazarov441
@sardorjumanazarov441 3 жыл бұрын
that was best ever, thanks
@RalphMaruva
@RalphMaruva 3 жыл бұрын
This guy has THE VOICE!
@Victor_Marius
@Victor_Marius 3 жыл бұрын
At Q4 is 101 not 4. It actually sets the array length to 101 and keeps any unset value to undefined and with a for...of it goes through all 101 elements, but with forEach or for...in uses only those 4 values (even if they are set to undefined later on). Actually I don't believe those values will be undefined but some other weird empty value (like the value is deleted) and you have to use a.hasOwnProperty(index) to check if there is anything. var a = [, 2]; a.hasOwnProperty(0) == false; a.hasOwnProperty(1) == true; a.length == 2; At Q13 the second option doesn't create a new function on the global scope (window) and then can be accessed via window.discountPrice? Anyway your choice is correct
@hosamgnaba3205
@hosamgnaba3205 3 жыл бұрын
thank you man after I watch this video and took the same test and successes with the top 15% . ohhhh yea
@jamjam3448
@jamjam3448 3 жыл бұрын
the total length is 101. But if the property(or key) of the array is a string, it doesn't affect its length.
@freedomanana3009
@freedomanana3009 3 жыл бұрын
that array length better to throw a index error ,and I guess the value V would be 1 because it’s rededined in f2, not a assignment.
@danutzz8
@danutzz8 3 жыл бұрын
great video !
@danutzz8
@danutzz8 3 жыл бұрын
I was thinking about 1 on Q12 the one with var v=1 , I 've just run the code and is apparently 1 lol I've nailed one :)) luckily seen a tutorial today that was just explaining let/var behave in a function. Explanation is that the 'console.log' is the F1 function and the nearest declaration is in the global scope which is 1.
@varaprasadreddy6420
@varaprasadreddy6420 3 жыл бұрын
I took this quiz before, I am in the top 5%.
@mind_of_a_darkhorse
@mind_of_a_darkhorse 3 жыл бұрын
Question 12 the correct answer is 1 because the f1 function looks for the first global variable v outside it's scope, which is var v = 1. Var v in the second function becomes a new variable trapped within the scope of the second function.
@mind_of_a_darkhorse
@mind_of_a_darkhorse 3 жыл бұрын
If the var in the f2 function was not used then and just v =2 was used it would have reassigned the global variable to 2.
@evergreen7781
@evergreen7781 3 жыл бұрын
I have to learn a lot... I was in top 15% of 824k Your video pointed out my mistakes...
@joshrice1010
@joshrice1010 2 жыл бұрын
var v = 1 var f1 = function(){ console.log(v) } var f2 = function() { var v = 2 f1() }; f2() it prints 1 because of scope, in funct 2 your declaring a new varaible inside its scope not reasigning and f1 doesnt know of a declared variables inside f2. like if you did v = 2 instead of using var then your taking the variable it has access to and modifying it
@Diallo268
@Diallo268 3 жыл бұрын
void is for IIFEs. I'm no expert, but basically it just means you don't want anything returned. There is another way to do it I believe if you wrap it in () so you don't have to use the keyword.
@AminSani
@AminSani 3 жыл бұрын
Please do it for React as well
@nativeKar
@nativeKar 3 жыл бұрын
You should try taking the React test - it's bloody confusing!
@WebDevSimplified
@WebDevSimplified 3 жыл бұрын
That will be one of the next ones I do!
@oluwadipegodwin9304
@oluwadipegodwin9304 3 жыл бұрын
Please web simplified, can you help me with knowing github? I create a project but pushing it to github is giving me big problem. How can you help me?
@VikasBhagwagar
@VikasBhagwagar 3 жыл бұрын
I have already cleared linkedin javascript assesment test because i have been coding javascript since last 20 years, but i am not smarter most youtubes devs to showcase what I know so far.
@wdesign1tobe
@wdesign1tobe 3 жыл бұрын
Can you please make a Front-end Development Assessment? Thanks
@excellencyjumo
@excellencyjumo 2 жыл бұрын
I was top 15% in about 2M people that have presently taken the test , pretty impressive after learning java- script for some weeks
@vitvitvitvitvitvitvitvit
@vitvitvitvitvitvitvitvit 2 жыл бұрын
The the test isn't impossible if you study xD
@servo5000
@servo5000 3 жыл бұрын
Is this JS test located within Linkedin somewhere?
@mehdi-vl5nn
@mehdi-vl5nn 2 жыл бұрын
10:58 it does in global scop if can't find it
@wdesign1tobe
@wdesign1tobe 3 жыл бұрын
can you please make a Linkedin's Front-end Development Assessment/ & NodeJs Assessment? Thanks
@aliqsson
@aliqsson 3 жыл бұрын
var supports functional scope, but not the block scope. For question 12 the answer was 1.
@soniablanche5672
@soniablanche5672 3 жыл бұрын
var is function scoped so "var v = 2" does not redefine the global v because you are declaring it inside a function
@migueldomingos4570
@migueldomingos4570 3 жыл бұрын
Where is the link for this quiz?
@drrandom1259
@drrandom1259 3 жыл бұрын
void is the return type of a function if it does not return anyting isn't it?
@ravalravi882
@ravalravi882 3 жыл бұрын
var a = [1,2,3]; a[100] = 100 console.log(a.length); => gives 101 here rest of element is undefinded
@tylordid2695
@tylordid2695 3 жыл бұрын
Would you teach one on one? If so, please let me know how much. Thank you Tylor
@football-is-divine
@football-is-divine 3 жыл бұрын
I became top 3% in JavaScript exam in LinkedIn
@shubhammudaliar4203
@shubhammudaliar4203 3 жыл бұрын
in question 12 in will print 1 because f1 functoin will get called
@aammssaamm
@aammssaamm 3 жыл бұрын
because var v redefined after f1 and not passed to f1.
@akbaryuldoshev8983
@akbaryuldoshev8983 3 жыл бұрын
On question 12 you made a mistake for sure. Because the second-time v variable is declared inside of the function as var v =2 which means it is different variable, it is not referencing the previous v variable to reassign the value of the previous v variable you have to reference it like v = 2; without var keyword.
@AnyFactor
@AnyFactor 3 жыл бұрын
I am a professional python dev, but I still haven’t passed the quiz yet. I always come only few percentage points below passing.
@MuhammadBilal-hq3xn
@MuhammadBilal-hq3xn 3 жыл бұрын
I got many different questions but i got 5% ❤️
@VictoriousVipin
@VictoriousVipin 3 жыл бұрын
I got a top 15% in that quiz..
@shazbaz5695
@shazbaz5695 3 жыл бұрын
for question 12 I got 1.
@Jason-mx8dl
@Jason-mx8dl 3 жыл бұрын
That’s right. When the console.log looks for ‘v’ within f1 and doesn’t find anything, it looks one level outside the execution context, not one level down the scope chain. One level outside of the f1 context is the global context where v = 1.
@kincunico
@kincunico Жыл бұрын
I'm pretty happy as I managed a 12/15.
@muaz840
@muaz840 3 жыл бұрын
what is link of this test
TypeScript Makes You A Faster Developer
9:14
Web Dev Simplified
Рет қаралды 70 М.
Can HTML Actually Be Hard? LinkedIn HTML Quiz
12:22
Web Dev Simplified
Рет қаралды 51 М.
Best KFC Homemade For My Son #cooking #shorts
00:58
BANKII
Рет қаралды 63 МЛН
Как бесплатно замутить iphone 15 pro max
00:59
ЖЕЛЕЗНЫЙ КОРОЛЬ
Рет қаралды 7 МЛН
Пранк пошел не по плану…🥲
00:59
Саша Квашеная
Рет қаралды 6 МЛН
5 Essential JavaScript Interview Questions
20:32
Coding With Chaim
Рет қаралды 90 М.
Google Coding Interview With A Competitive Programmer
54:17
Clément Mihailescu
Рет қаралды 2,5 МЛН
Another 5 Must Know JavaScript Features That Almost Nobody Knows
22:42
Web Dev Simplified
Рет қаралды 213 М.
Top 10 Linux Job Interview Questions
16:04
tutoriaLinux
Рет қаралды 2,3 МЛН
How Good Are You At JavaScript? - JavaScript QUIZ!
33:13
Clément Mihailescu
Рет қаралды 37 М.
ex-FAANG Developer vs "Hardest" JavaScript Quiz
12:33
Conner Ardman
Рет қаралды 25 М.
5 MORE Must Know JavaScript Features That Almost Nobody Knows
18:05
Web Dev Simplified
Рет қаралды 179 М.
Are You Making These CSS Height Mistakes?
8:54
Web Dev Simplified
Рет қаралды 125 М.
Junior Vs Senior Code - How To Write Better Code
22:13
Web Dev Simplified
Рет қаралды 1,1 МЛН
Best KFC Homemade For My Son #cooking #shorts
00:58
BANKII
Рет қаралды 63 МЛН