Home  • Programming • JavaScript

Formal Parameter vs Actual Parameter

formal-parameter-from-the-called

Formal Parameter

From the called function, Parameter is called Formal Parameter . These are written inside of parenthesis at the time of function definition. কল্ড ফাংশন এ Parameter কে Formal Paramter বলা হয়। আমাদের নিচের উদাহরনে, function calculate হল Called function, যেহেতু এই ফাংশন, function totalCost দিয়ে কল হচ্ছে। যখন ফাংশন Define করা হয় তখন ফাংশনের প্রথম বন্ধনীর ভিতরে Formal Parameter লিখা হয়। আমাদের নিচের উদাহরনের x এবং y হল Formal Parameter.

Actual Parameter

From the calling function, Argument is called Actual Parameter. Those are written within parenthesis at the time of function call. আমাদের উপরের উদাহরনে, function totalCost হল Calling function যেহেতু এ নিজে, function calculate কে কল করে। সুতরাং Calling function থেকে Argument কে Actual Parameter বলা হয়। উদাহরনে function calculate এর প্রথম বন্ধনীর ভিতর 50, 50 হল Actual Parameter.

Comments 1


nice

Share

About Author
Zinia Islam
Copyright © 2024. Powered by Intellect Software Ltd