Hey Rowdy Coders, seems there is an issue with question 20. It is giving different result in different platforms, The answer that my VSCode giving is wrong, so please run it in your device! Sorry for the inconvenience!
in shallow copy when we change primitive value it won't change for other i.e arr2 , if we change non-primitive value then it affect other i.e arr2 for example=> 1)changing primitive value const user1={ name:"chandan", age:25, address:{state:"up",city:"noida"} } const user2={...user1} user1.name="aryan" // primitive console.log(user1); console.log(user2); ans=> user2 will not change 2) changing non-primitive value const user1={ name:"chandan", age:25, address:{state:"up",city:"noida"} } const user2={...user1} user1.address.city="varanasi" // non primitive console.log(user1); console.log(user2); Ans=> it affect user2 --------------------------------- for arr1[0][1] = "1"; arr1[0][0] = "0"; it will affect arr2 (non-primitive change) but for arr1[1] = 33; arr1[0] = 22; no effect on arr2 (primitive change)
Great video! Really helpful to see the top 50 most asked JavaScript logical interview questions. Please make more videos like this on JS and React. Keep up the awesome content!
Hello It is really helpful to brush up the js skills. It would be good if you could create video of mostly asked coding questions based out of ‘array of objects’, utilizing array methods
Y hindi. Do you think everyone understands! Get educated in English as a software it's minimal skill. Stop demanding forcing others let them do whatever they wanted to
Hey Rowdy Coders, seems there is an issue with question 20. It is giving different result in different platforms,
The answer that my VSCode giving is wrong, so please run it in your device!
Sorry for the inconvenience!
in shallow copy when we change primitive value it won't change for other i.e arr2 , if we change non-primitive value then it affect other i.e arr2
for example=>
1)changing primitive value
const user1={
name:"chandan",
age:25,
address:{state:"up",city:"noida"}
}
const user2={...user1}
user1.name="aryan" // primitive
console.log(user1);
console.log(user2);
ans=> user2 will not change
2) changing non-primitive value
const user1={
name:"chandan",
age:25,
address:{state:"up",city:"noida"}
}
const user2={...user1}
user1.address.city="varanasi" // non primitive
console.log(user1);
console.log(user2);
Ans=> it affect user2
---------------------------------
for arr1[0][1] = "1";
arr1[0][0] = "0";
it will affect arr2 (non-primitive change)
but for
arr1[1] = 33;
arr1[0] = 22;
no effect on arr2 (primitive change)
Question 20 alos correct, actually you change first array1 value at the time of run so that's why Array 2 is similar to array 1
Great video! Really helpful to see the top 50 most asked JavaScript logical interview questions. Please make more videos like this on JS and React. Keep up the awesome content!
@@mayurthemaskar9182 thank you!🙏
your questions are good but your explanations are Rapid and uncleared.. please explain in a clear context..
Best of the best to brush up JavaScript thanks a lot 💕💞❣
Thank you 🙏 very much glad🥳🥳
Hello It is really helpful to brush up the js skills.
It would be good if you could create video of mostly asked coding questions based out of ‘array of objects’, utilizing array methods
@@archiejain1974thank you!
Sure will create more videos on ‘Array of Objects!’
Good
Awesome 🎉
Thank you🙏🤗
I am fresher preparing frontend interview can this video help me in interview or this is for senior developer
Only few of the questions in this Video are in scope for freshers. I will be creating separate content for freshers exclusively.
@@RowdyCoders Annayya, could you please provide me with a JavaScript fresher interview video link?
Question 20 explanation wrong.
Seems this question result itself is giving different in different platforms. My bad!
@@RowdyCoders appreciate your replay.
Question 20 alos correct, actually you change first array1 value at the time of run so that's why Array 2 is similar to array 1
You should try to explain in hindi
It will be more beneficial for you and for also students
He's trying his best learn from it !!
Y hindi. Do you think everyone understands! Get educated in English as a software it's minimal skill. Stop demanding forcing others let them do whatever they wanted to
English is the best and the most standard way to communicate in any IT industry or any firm. You should try to learn English, not Hindi.
Question 5 - last part explanation not cleared.
Last part is closure to fix first part issue.
Great bro
@@rajeevnathverma7877 🙏 Thank you!
Q21 why there are 3 undefined?