Lesson 19 of 23
Call by Reference: Swap
9 min 35 XP
Variable चा address पाठवला की function ते variable स्वतःच बदलू शकते. scanf(&x) नेमके असेच काम करते, आणि अशाच प्रकारे एखादे function एकापेक्षा जास्त values परत देते.
Example: edit me and press Run
Output Loading C (first time takes a few seconds)
Press Run to see the result here.Function ला array पाठवल्यास त्याच्या पहिल्या घटकाचा address जातो, म्हणून function मध्ये केलेले बदल main मध्येही दिसतात.