Java is pass/call by value or pass/call by reference [MOST IMP. JAVA INTERVIEW QUESTION]| ode Decode

  Рет қаралды 154,713

Code Decode

Code Decode

Күн бұрын

Пікірлер: 184
@shubhamtagalpallewar7125
@shubhamtagalpallewar7125 4 жыл бұрын
Thank you ma'am, I have been asked this question in interview and I was unable to answer properly, now I am confident on this topic.
@CodeDecode
@CodeDecode 4 жыл бұрын
M glad that you are. :) May you reach all the heights in your career
@nndsmsjsjs2501
@nndsmsjsjs2501 Жыл бұрын
@@CodeDecode mam pass By Value Means Call by value Right?
@Neerajkushwaha-uz8wo
@Neerajkushwaha-uz8wo 10 ай бұрын
Us😄
@sravyayerrams
@sravyayerrams Жыл бұрын
Pass By Reference: Changing the value of the real address in the memory. Pass By Value: Copying the value to another location and so the real value is not changed.(java)
@CodeDecode
@CodeDecode Жыл бұрын
👍👍
@amitjoshi940
@amitjoshi940 6 ай бұрын
Java 8 : pass by value or pass by reference
@dheebanm3207
@dheebanm3207 3 жыл бұрын
Real time example is very easy to understand, thank you...
@CodeDecode
@CodeDecode 3 жыл бұрын
Thanks Dheepu 👍
@vigneshramesh7691
@vigneshramesh7691 4 жыл бұрын
With the Last example all the doubts are cleared that Java is pass by value. "Just passing a reference as value. " 8:12 - 8:16
@CodeDecode
@CodeDecode 4 жыл бұрын
👍👍m glad you understood this so clearly 👍 appreciable
@roobanraj28
@roobanraj28 Жыл бұрын
Thanks for this crystal Clear Explanantion .
@CodeDecode
@CodeDecode Жыл бұрын
👍🙂
@renejacques8288
@renejacques8288 3 жыл бұрын
Clear explanation. I hope that'll help not to forget it again.
@CodeDecode
@CodeDecode 3 жыл бұрын
Thanks 👍. Yes hopefully 😊
@TheMilinmodi
@TheMilinmodi 8 ай бұрын
Thank you so much mam. Much clear till you convinced that java is pass by value but when you explained with java object then it becomes confusing. Please explain in detail for when we are changing the value using object. Also, Congratulations to you for new subscriber as well. Gone thru channel and found it very helpful.
@CodeDecode
@CodeDecode 8 ай бұрын
Sure we will create a more clarity video on this. Thanks 👍
@avinashkumargond3291
@avinashkumargond3291 7 ай бұрын
Last wala example related to refreneces, was really osm
@abhivela
@abhivela Жыл бұрын
The topics you cover here are so unique !!! I have seen many tutorials for Java..... But the type of topics you cover here and the explanation is top notch!!! ❤ Thank you for your efforts 🎉❤
@CodeDecode
@CodeDecode Жыл бұрын
Thanks Abhi 😊👍
@anurani7084
@anurani7084 2 жыл бұрын
Thankyou mam.. for explaning this in a wonderful way
@secretsociety2510
@secretsociety2510 3 жыл бұрын
This is very helpful video. Thanks a lot for explaining this👍
@CodeDecode
@CodeDecode 3 жыл бұрын
Thanks Amogh for the nice words....
@dhananajaykrishna8259
@dhananajaykrishna8259 4 жыл бұрын
Simple and clear explanation. Aweesome!!
@CodeDecode
@CodeDecode 4 жыл бұрын
Thanks 👍
@WAQASAHMAD-cw1ds
@WAQASAHMAD-cw1ds 3 жыл бұрын
Thank you so much Ma'm to clearing my Concept... & Congratulations for a new subscriber 😉
@CodeDecode
@CodeDecode 3 жыл бұрын
Thanks Waqas 👍👍
@Asadullah-bg5ny
@Asadullah-bg5ny 3 жыл бұрын
what a brilliant way of explaining , finally got the answer.
@CodeDecode
@CodeDecode 3 жыл бұрын
Thanks 🙃
@gsathyanarayana7366
@gsathyanarayana7366 3 жыл бұрын
Thank You for making this video. Need small clarification, when primitive variable 'a' passed as an argument to a method you said java copies the value of 'a' to a new memory location and that location address passed to that method as argument so value wouldn't update in parent class ? Same theory isn't applicable to objects ? Java doesn't copy the object to different memory location and sends that memory location address to method as an argument ?
@abduldaniq5004
@abduldaniq5004 3 жыл бұрын
Exactly I got that same doubt
@nrusinghacharya
@nrusinghacharya 3 жыл бұрын
The problem you're facing here is statements like In Java, Objects are passed by reference, and primitives are passed by value. This is half incorrect. Everyone can easily agree that primitives are passed by value; there's no such thing in Java as a pointer/reference to a primitive. However, Objects are not passed by reference. A correct statement would be Object references are passed by value.
@shiva3895
@shiva3895 3 жыл бұрын
@code_decode small question. If java is pass by value & values is passed after copying it. That means object reference value should also be copied first and than passed. If Yes, a memory address is being copied and that is my missconcecpt. Can you please explain. Thanks!
@singhji4149
@singhji4149 10 ай бұрын
Great explanation 👌🙏
@CodeDecode
@CodeDecode 10 ай бұрын
Thanks
@siddheshtoraskar9537
@siddheshtoraskar9537 4 жыл бұрын
Great explanation with nice example 👍🏻
@CodeDecode
@CodeDecode 4 жыл бұрын
Thanks 👍
@nagar4u
@nagar4u 3 жыл бұрын
Good content. Keep growing. Keep it up.
@CodeDecode
@CodeDecode 3 жыл бұрын
Thanks 👍
@SaratKumar-qk7lu
@SaratKumar-qk7lu 4 жыл бұрын
Good to see this channel.
@CodeDecode
@CodeDecode 4 жыл бұрын
M glad you liked it
@nivassimhadri2229
@nivassimhadri2229 3 жыл бұрын
seen many videos from your channel, everything is on point explanation and also the slides are perfect to read even though there is no audio. where can we find all your presentation slides?
@CodeDecode
@CodeDecode 3 жыл бұрын
Thanks a ton Nivas 🙂👍
@prudhvinadh5786
@prudhvinadh5786 Жыл бұрын
Nice explanation
@CodeDecode
@CodeDecode Жыл бұрын
Thanks 😊👍
@sanketh768
@sanketh768 3 жыл бұрын
Thanks mam, please continue to make videos like these to help people. Maybe after java sometother topic like database
@CodeDecode
@CodeDecode 3 жыл бұрын
Yes, definitely
@gargijoshi5186
@gargijoshi5186 3 жыл бұрын
Best explanation by far
@CodeDecode
@CodeDecode 3 жыл бұрын
Thanks Gargi
@satyamshah9164
@satyamshah9164 4 жыл бұрын
Very clear explanation mam!
@CodeDecode
@CodeDecode 4 жыл бұрын
Thanks :)
@navneettripathi2110
@navneettripathi2110 4 жыл бұрын
Commenting for the 3rd time....for comparable comparator detailed video...
@CodeDecode
@CodeDecode 4 жыл бұрын
. Sorry for keeping your topic on hold. I needed to cover basics first for that video. Now since we have covered most of the basics we can take that topic now.
@CodeDecode
@CodeDecode 4 жыл бұрын
@navneet All you need to know about comparable and comparator Please like and subscribe. kzbin.info/aero/PLyHJZXNdCXscG1g50RaLZdXgBhC-C7dCy
@jeeteshkumar11
@jeeteshkumar11 4 ай бұрын
Great explanation
@CodeDecode
@CodeDecode 4 ай бұрын
Thanks 👍
@sabbaticalcountdown
@sabbaticalcountdown 3 жыл бұрын
You did an excellent job explaining, thank you so much!! =)
@CodeDecode
@CodeDecode 3 жыл бұрын
You are Welcome ....
@abhishekarya8108
@abhishekarya8108 3 жыл бұрын
Nice explanation!
@CodeDecode
@CodeDecode 3 жыл бұрын
Thanks abhishek
@tapanparida3176
@tapanparida3176 2 жыл бұрын
God bless you mam for your good work…your work really helps people….keep up!!!
@CodeDecode
@CodeDecode 2 жыл бұрын
Thanks a lot Tapan 🙂👍
@sanketh768
@sanketh768 2 жыл бұрын
nice explanation however had a doubt, since java is pass by reference for object as per your example for Animal Object. i tried the same example with Integer since its an Object, the same was not happening. Please check the below example. public static void main(String[] args) { Integer i = 10; change(i); System.out.println("main"+i);//op is 10 } public static void change(Integer i) { i =11; System.out.println("method"+i);//op is 11 }
@thivagarmurugan2955
@thivagarmurugan2955 2 жыл бұрын
u creating primitive datatypes in main function and u just passing copy of i in change method so any changes made in change only affected in change alone not in main method the both different
@niteshbhati6496
@niteshbhati6496 Жыл бұрын
It is because all primitive wrapper classes (Integer, Byte, Long, Float, Double, Character, Boolean, and Short) are immutable in Java
@Dharmik_Vibes
@Dharmik_Vibes 3 күн бұрын
primitive wrapper classes in Java (such as Integer, Double, Character, Boolean, Long, Short, Byte, and Float) are immutable. Explanation: An immutable object is an object whose state cannot be modified after it is created. In the case of primitive wrapper classes in Java, once an instance of a wrapper class is created, its value cannot be changed.
@kasiyedumati9423
@kasiyedumati9423 3 жыл бұрын
Awesome explanation
@CodeDecode
@CodeDecode 3 жыл бұрын
Thanks 👍👍
@saikumargoud3257
@saikumargoud3257 2 жыл бұрын
Thank you mam I had understand very clearly but one doubt raised in mind that why java is particularly called pass by value here we are doing both pass by value and pass by reference can you please explain mam?
@vigneshgvs
@vigneshgvs Жыл бұрын
chatgpt gave below sample on justification: In Java, you always pass the value of the reference to an object when you pass it to a method. This means you are passing a copy of the reference, not the actual object. Java itself does not provide a way to pass the actual object by reference as some other languages might. Even when you pass an object as a method parameter, you're still passing a copy of the reference to that object. (kindda pass by value). However, the confusion often arises because operations on the object itself (like modifying its fields) are visible outside the method, giving the appearance that the object is being passed by reference. class Person { String name; Person(String name) { this.name = name; } } public class Main { public static void modifyReference(Person person) { person = new Person("John"); // This reassigns the reference locally, not affecting the original reference. } public static void modifyObjectFields(Person person) { person.name = "Jane"; // This modifies the actual object, affecting the original object. } public static void main(String[] args) { Person person = new Person("Alice"); modifyReference(person); System.out.println(person.name); // Output: Alice modifyObjectFields(person); System.out.println(person.name); // Output: Jane } }
@akah2
@akah2 Жыл бұрын
Excellent
@CodeDecode
@CodeDecode Жыл бұрын
thanks
@pankajchandel1000
@pankajchandel1000 3 жыл бұрын
Best explanation !
@CodeDecode
@CodeDecode 3 жыл бұрын
Thanks sanjay
@alfiyakhan4580
@alfiyakhan4580 Жыл бұрын
Ma'am I am having a doubt, starting 4 mins of the video where you said "to access a private method you have to make it static", I didn't get that point. Please explain.
@veerannajakkula
@veerannajakkula 3 жыл бұрын
Good explanation. Thank You. You can also pass any list to a method and update the list in called method to provide more in-depth analysis.
@CodeDecode
@CodeDecode 3 жыл бұрын
Sure 👍
@drashtinaik5751
@drashtinaik5751 3 жыл бұрын
It is perfect explanation. But still, can you please add new video on this with detail explanation and example.
@CodeDecode
@CodeDecode 3 жыл бұрын
Sure Drashti, what do u want us to cover in that?
@drashtinaik5751
@drashtinaik5751 3 жыл бұрын
@@CodeDecode In detail with heap and stack memory allocation that will give much clarity .
@drashtinaik5751
@drashtinaik5751 3 жыл бұрын
@@CodeDecode And thank you for fastest reply.
@CodeDecode
@CodeDecode 3 жыл бұрын
Sure. You need Java memory management. Right?
@CodeDecode
@CodeDecode 3 жыл бұрын
No worries 😊😊
@commenter9451
@commenter9451 2 жыл бұрын
Best explanation ❤️
@CodeDecode
@CodeDecode 2 жыл бұрын
Thanks
@abhishekganguly165
@abhishekganguly165 3 жыл бұрын
Hi mam, In 1:18- 1:21 aapne kaha ki "we are changing the value at the real address in the memory" this is pass by referance. and that is what is happening in your last example. when you passes a value the it is changing its value. If you are passing a referance, then the address of the object is getting copied, and it is changing the value inside that object. So can you Please expain me in details for call by referance with a heap and stack memory representation. if possible.
@abhishekganguly165
@abhishekganguly165 3 жыл бұрын
I got it first in google search that: Pass-by-reference means to pass the reference of an argument in the calling function to the corresponding formal parameter of the called function. The called function can modify the value of the argument by using its reference passed in. The following example shows how arguments are passed by reference. So why cant we say java supports both. ?
@sriharikaranam3330
@sriharikaranam3330 3 жыл бұрын
Java mainly dealing with 2 types.. 1. Primitive 2. Object In first case java is passing primitive value as argument of method. So any changes happened in method then new primitive will be created(which is short lived variable). It wont affect original primitive. In second case, lets say reference is 101011. Then java is passing that reference as argument of method. If any changes happened, reference value not get affected. Java will modify the object which is pointing to that reference. The reference value will be maintained as same. So Java is pass by value... In first case if original value changed, or in second case if the reference got changed, then it will be pass by reference..
@abhishekganguly165
@abhishekganguly165 3 жыл бұрын
@@sriharikaranam3330 what you told I got. but point is what is pass by reference then? we will pass the referance and address will be change? or pass by reference is we pass the referance and the value inside the referance got change?
@sdef719
@sdef719 4 жыл бұрын
Best explanation. Love it.
@CodeDecode
@CodeDecode 4 жыл бұрын
Thanks 👍
@venkatesanelumalai-q5c
@venkatesanelumalai-q5c Жыл бұрын
Nice Video
@CodeDecode
@CodeDecode Жыл бұрын
Thanks
@yoshitamahajan353
@yoshitamahajan353 4 жыл бұрын
In pass by value u mean the value doesn't change and in pass by reference value changed so ideally value changes when reference passed so it should be pass by reference?? Do let me know as I m still confused about this so
@CodeDecode
@CodeDecode 4 жыл бұрын
Ok so let's understand it in this way. Reference is nothing but memory address. Now when ever you change any thing at memory address, the change is reflected every where. Now in case of Java, This memory address is sent as values in arguments to methods. So it's pass by value, but since memory address or reference is passed as values hence changes are reflected every where
@CodeDecode
@CodeDecode 4 жыл бұрын
Now do you get the point?
@yoshitamahajan353
@yoshitamahajan353 4 жыл бұрын
@@CodeDecode and same in case of pass by value we create copy of the variable and pass the copy.. so again we pass value.. 1. In call by value , we create copy of the value and pass to the method 2. In call by reference,we pass the value of memory address to which the object is passed So in both cases value is passed hence java is call by value Am I r8? Please correct me if I m wrong..
@abhishekganguly165
@abhishekganguly165 3 жыл бұрын
@@yoshitamahajan353 but both point 1 and 2 got satisfied right? so why this is only pass by value?? why it is not pass by refrerance?
@gokulaher2476
@gokulaher2476 3 жыл бұрын
java is strictly pass-by-value method 'arguments' "value" initializes and assigns newly created method 'parameter'value
@CodeDecode
@CodeDecode 3 жыл бұрын
That's what we have discussed here also right?
@gokulaher2476
@gokulaher2476 3 жыл бұрын
Perfect... Your video on java 8 Predicate,function, supplier,consumer Bi.... Predicate, fu,ction,consumer and stream are very well explained..
@ayyappag7097
@ayyappag7097 2 жыл бұрын
Need small clarification, when primitive variable 'a' passed as an argument to a method you said java copies the value of 'a' to a new memory location and that location address passed to that method as argument so value wouldn't update in parent class ? Same theory isn't applicable to objects ? Java doesn't copy the object to different memory location and sends that memory location address to method as an argument ?
@vaniraj8456
@vaniraj8456 2 жыл бұрын
No here because we send the reference variable which holds the memory address of an object rather than holding the object
@AMANSINGH-yv4vv
@AMANSINGH-yv4vv 3 ай бұрын
Thanks so much ya!
@CodeDecode
@CodeDecode 3 ай бұрын
🙂👍
@arpanbanejee5143
@arpanbanejee5143 3 жыл бұрын
Its still not clear to me- Example 1- If I just add tempList in my base case then I get [] [] [] [] as and, as it holds the reference and it gets modified in the recursive calls, so at each step when it hits the base case I need to capture the then state of the arraylist and store it in the res. private static void backtrack(List list, List tempList, int[] nums, int remain, int start) { if (start >= nums.length && remain != 0) { return; } else if (remain == 0) { list.add(new ArrayList(tempList));--> if I do not make a new list out of it , it gets modified. REFERENCE VAIRABLE THATS WHY!! } else { for (int i = start; i < nums.length; i++) { if (nums[i] > remain) { break; } if ((i > start && nums[i] == nums[i - 1])) { continue; // skip duplicates } tempList.add(nums[i]); backtrack(list, tempList, nums, remain - nums[i], i + 1); tempList.remove(tempList.size() - 1); } } } But in this example, even if I set the prev pointer when my left recurison ends for the first time ,still its value is null when it backtracks- private void convertBtToDll(Node temp, Node prev) { if (temp == null) { return; } convertBtToDll(temp.left, prev); // marks the head -- leftmost node if (prev == null) { head = temp; } // make the links for the other nodes else { temp.left = prev; prev.right = temp; } prev = temp; ----> even if I set it here it is null?????? why? isn't it a reference variable? convertBtToDll(temp.right, prev); } public static void main(String[] args) { ConvertBTtoDLL2 btToDll = new ConvertBTtoDLL2(); Node root = new Node(10); root = new Node(10); root.left = new Node(12); root.right = new Node(15); root.left.left = new Node(25); root.left.right = new Node(30); root.right.left = new Node(36); System.out.println("After conversion to DLL"); Node temp = root; Node prev = null; btToDll.convertBtToDll(temp, prev); btToDll.printDll(); }
@hariprasad2697
@hariprasad2697 2 жыл бұрын
Super 🌟
@CodeDecode
@CodeDecode 2 жыл бұрын
Thanks hari
@omprakash4558
@omprakash4558 3 жыл бұрын
So can we say, java is pass by reference for non-premitive data types?
@chaturvedisurbhi05
@chaturvedisurbhi05 3 жыл бұрын
So we can say reference is passed as value so reference doesn't change but object value gets change in case of passing reference?
@deepkansara6547
@deepkansara6547 9 ай бұрын
Consider this snippet: public static void main(String[] args) { Integer i = new Integer(3); modify(i); System.out.println(i); //Prints 3 } static void modify(Integer i) { i = i * 10; } In this case I have created the object of the Integer class and changed it's value. So as per this video, object can be changed as it is passed as a reference, I am getting the output as the same object it has been initialized with instead of modified version. In case of arrays, we can do modify the values of array. So I just want to know what kind of values are passed by value and what kind of values are passed by reference?? Anyone please help.
@arpit2283
@arpit2283 9 ай бұрын
Bro, String and Wrapper classes like Integer , Double , BigDecimal are immutable classes. So , the value is not changed there.
@azizbekrasulmetov9293
@azizbekrasulmetov9293 Жыл бұрын
Did u said that u a passing object by value at the end ? When u actually passing the reference!
@barathiraiyarul4498
@barathiraiyarul4498 2 жыл бұрын
Thanks 👍
@CodeDecode
@CodeDecode 2 жыл бұрын
👍
@aravindhravi2307
@aravindhravi2307 3 жыл бұрын
THIS IS GR8!!!
@CodeDecode
@CodeDecode 3 жыл бұрын
Thanks 👍👍
@gokudominic3328
@gokudominic3328 4 жыл бұрын
Why java is not both i.e. java is pass by value as well as pass by reference.??plzz ans
@CodeDecode
@CodeDecode 4 жыл бұрын
Because Java is pass by value. That's why it's not both.
@gokudominic3328
@gokudominic3328 4 жыл бұрын
No mam i mean java is always pass by value but by vedio java is seems to be both so how can you say tha pass by reference is equivalent to pass by value??
@gokudominic3328
@gokudominic3328 4 жыл бұрын
My actual question is how pass by reference is equivalent to pass by value??
@CodeDecode
@CodeDecode 4 жыл бұрын
Consider a scenerio : You are passing address or memory location itself.
@CodeDecode
@CodeDecode 4 жыл бұрын
So while you are passing your variable as formal argument of the method, it is considered as pass by value. So yes you are correct when you say it's pass by value but actually in java, you pass memory reference itself as a value.
@poornachanderraonadipelly6128
@poornachanderraonadipelly6128 2 жыл бұрын
Mam im getting really confused with this concept? Please help me to understand
@Rohit-yo4ik
@Rohit-yo4ik 3 жыл бұрын
Today this question asked by interviwer...I got trapped... there is mutable/immutable thing also matter to this pass by value or reference. Please clear this also.
@NareshKumar-dw9xp
@NareshKumar-dw9xp 4 жыл бұрын
Yesterday I had an interview with Nokia , it was an on-campus placement interview.. You know what, they asked me why java is passed by value ? And they wouldn't satisfied with my answer. And hence I got rejected ☹️☹️.
@CodeDecode
@CodeDecode 4 жыл бұрын
Was I able to clear your query? Did you watch this video before or you watched this now?
@NareshKumar-dw9xp
@NareshKumar-dw9xp 4 жыл бұрын
@@CodeDecode That's the unfortunate mam. I watched it now. But noww I am clear amd confident. Probably next week I have an interview of TCS Digital SDE . I will never repeat this mistake ever. Thank you so much for this.
@CodeDecode
@CodeDecode 4 жыл бұрын
Don't worry. As a fresher you will get ample of opportunities and each interview will teach you something new.
@CodeDecode
@CodeDecode 4 жыл бұрын
Take it positively. Just make sure that you are clear with your basics. They will not go much high level. Prepare core Java thoroughly and I am sure you will crack something really worth cracking 👍
@CodeDecode
@CodeDecode 4 жыл бұрын
All the best for the future companies. 👍
@asutoshsahoo3776
@asutoshsahoo3776 4 жыл бұрын
Got it that , the reference we pass in java function is as a reference to memory location as value, so though we pass a reference it is still Pass by Value, but then what is Pass by Reference exactly
@CodeDecode
@CodeDecode 4 жыл бұрын
Your understanding is correct. Pass by reference is just a concept where you pass reference of variable or so called memory address of that variable itself as the formal argument. Doing so, if you change any thing locally in the method, the changes are no more local to that method, it's reflected every where Why so? Because you changed at the memory itself. Right? Now you got it ? If it would have been pass by value, different memory location is created for the formal argument and value will be copied. Hence if you change that value locally, the changes will be in newly created memory location and not in the original one
@deneshbabu5199
@deneshbabu5199 4 жыл бұрын
Then what exactly pass by reference?
@abhishekganguly165
@abhishekganguly165 3 жыл бұрын
@@deneshbabu5199 same question bhai.
@abhishek_67
@abhishek_67 2 жыл бұрын
Hum value bhi pass kr rhe hai aur object reference bhi pass kr pa rahe hai to java sirf passed by value kyu 🤔?
@akshaydeshmukh1433
@akshaydeshmukh1433 2 жыл бұрын
call by rfrnce vs pass by rfrence same or dfrnt
@swapnilhadge7383
@swapnilhadge7383 3 жыл бұрын
You missed to mention difference between int and animal ...
@hasangalakdinu
@hasangalakdinu 7 ай бұрын
thanks!!!
@CodeDecode
@CodeDecode 6 ай бұрын
You're welcome!
@sharfan22010
@sharfan22010 4 жыл бұрын
Thankyou miss👍
@MultiMoonlight
@MultiMoonlight 10 ай бұрын
Ma'am is your name Sana?
@temuryakhyoev5922
@temuryakhyoev5922 3 жыл бұрын
still a bit confusing about pass the object as a parameter
@paggybhangale
@paggybhangale 2 жыл бұрын
how to write junit ? myovject oldermethod() { other call// hashmap map = new hashmap(): NewObj obj = service.myservice(map); //logic value = map.get(0); // here i am getting null pointer in junit test return myobject; } class myservice{ NewObj myservice(hashmap map) { //logic map.put(key,value): return Newobj; } } after that i am getting null if i mock the myservice ...how to write junit for oldermethod()
@sahilbhasin2112
@sahilbhasin2112 4 жыл бұрын
gud job
@CodeDecode
@CodeDecode 4 жыл бұрын
Thanks :)
@hhcdghjjgsdrt235
@hhcdghjjgsdrt235 Жыл бұрын
you rock
@CodeDecode
@CodeDecode Жыл бұрын
:)
@SaiAbitathaDUCIC
@SaiAbitathaDUCIC 3 жыл бұрын
My exam begins in 2 hours 🙏
@CodeDecode
@CodeDecode 3 жыл бұрын
All the best 👍💯
@nazimmohammad6984
@nazimmohammad6984 3 жыл бұрын
Pl make it more clear.
@siddharthb2226
@siddharthb2226 3 жыл бұрын
vera level
@CodeDecode
@CodeDecode 3 жыл бұрын
Thanks
@hasnainansari6279
@hasnainansari6279 4 жыл бұрын
I m still confused ⁉️
@CodeDecode
@CodeDecode 4 жыл бұрын
java is pass by value. But if you pass a reference variable as an argument and that changes then it is because you are passing memory reference as value. Hence it's never pass by reference. It's always pass by value.
@CodeDecode
@CodeDecode 4 жыл бұрын
Still confused??
@littlethings2250
@littlethings2250 4 жыл бұрын
@@CodeDecode : passing memory reference as a value? But here we are not working on copy, instead the actual object itself isn't it? And in C, the concept of pointers and reference, there we pass reference as a reference or value?
@achyuth2424
@achyuth2424 4 жыл бұрын
Not understood please give more detail easy way of understanding
@CodeDecode
@CodeDecode 4 жыл бұрын
Explaination : java is pass by value. But if you pass a reference variable as an argument and that changes then it is because you are passing memory reference as value. Hence it's never pass by reference. It's always pass by value. Still if it's not clear then please let me know I will put more examples for you.
@achyuth2424
@achyuth2424 4 жыл бұрын
@@CodeDecode more examples please
@guntakasomeshwar8262
@guntakasomeshwar8262 3 жыл бұрын
I am unable to understand madam
@shivprasadgonare4474
@shivprasadgonare4474 2 ай бұрын
plz provide notes
@divyagracie
@divyagracie 2 жыл бұрын
02:51
@unknownuser-wr3zm
@unknownuser-wr3zm 3 жыл бұрын
tq
@CodeDecode
@CodeDecode 3 жыл бұрын
👍
@cousinslove7209
@cousinslove7209 4 жыл бұрын
Slow slow madam , not all members are quick learners as like you
@CodeDecode
@CodeDecode 4 жыл бұрын
Will try to reduce pace from next videos 👍
@GameXanime63
@GameXanime63 4 жыл бұрын
U can do by urself if u don't know the playback option just click on the three dot and u can this playback option where u can reduce the speed of the vdo btw thank me later
@lazylizarts
@lazylizarts 2 жыл бұрын
JAVA IS ALWAYS PASS BY VALUE ALWAYS
@CodeDecode
@CodeDecode 2 жыл бұрын
Can you please explain how?
@lazylizarts
@lazylizarts 2 жыл бұрын
@@CodeDecode its appropriate to say "Object reference is passed by value" for Non primitive type
@horuscoming
@horuscoming 4 жыл бұрын
You got to activate windows.
@CodeDecode
@CodeDecode 4 жыл бұрын
Yeah will do that for sure...
@sudipghimire4823
@sudipghimire4823 3 жыл бұрын
This is too much of a hindi accent to take in..
@CodeDecode
@CodeDecode 3 жыл бұрын
We are so sorry Sudip that our mother tongue is hindi. 👍
@hey_babe1557
@hey_babe1557 3 жыл бұрын
The video views is equal to your subscriber count
@CodeDecode
@CodeDecode 3 жыл бұрын
Nice observation Pradeep🙂👍
@hey_babe1557
@hey_babe1557 3 жыл бұрын
@@CodeDecode 😁
@venkatesanelumalai-q5c
@venkatesanelumalai-q5c Жыл бұрын
Good Video
@CodeDecode
@CodeDecode Жыл бұрын
Thanks
人是不能做到吗?#火影忍者 #家人  #佐助
00:20
火影忍者一家
Рет қаралды 20 МЛН
1% vs 100% #beatbox #tiktok
01:10
BeatboxJCOP
Рет қаралды 66 МЛН
Pass By Value and Pass By Reference In Java | Java Tutorials
26:02
What is Call By Value & Call By Reference In Java - Core Java - Part -12
14:10
Naveen AutomationLabs
Рет қаралды 109 М.
Call By Value & Call By Reference in C
8:34
Neso Academy
Рет қаралды 1,4 МЛН
Pass by Value and Pass by Reference in Java Video Tutorial
15:42
LearningLad
Рет қаралды 84 М.
Master Optional in Java 8: Complete Guide for Beginners
15:30
Engineering Digest
Рет қаралды 17 М.
Java is ALWAYS Pass By Value. Here's Why
5:22
Coding with John
Рет қаралды 127 М.
Máy Đếm Tiền Tính Tổng Chính Xác #shorts
0:26
Review Máy Đếm Tiền
Рет қаралды 859 М.
Sony PlayStation за 700 000 рублей!
1:00
Wylsacom
Рет қаралды 432 М.