জাভাস্ক্রিপ্ট apply() মেথড call() মেথডের মতোই, তবে এটি ফাংশন প্যারামিটারগুলো অ্যারে হিসেবে বিবেচনা করে। নিচের উদাহরণটি চালিয়ে apply() মেথড বাস্তবায়ন শিখুন।
উদাহরণ
<html> <head> <script> document.write("The highest number in the array list: "); document.write(Math.max.apply(null,[50,90,18, 87])); document </script> </head> <body> </body> </html>
আউটপুট
The highest number in the array list: 90