Parameter Passing Methods MCQs

30 min Score: 0 Attempted: 0/30 Subscribe
1. Which of the following is a method of parameter passing?





2. In call by value, what happens to the actual parameter?





3. Which parameter passing method allows the function to modify the actual parameter?





4. What is the main disadvantage of call by reference?





5. In call by result, when is the actual parameter updated?





6. Call by value-result is also known as:





7. Which of the following is true about call by name?





8. Call by constant reference is mainly used to:





9. Which parameter passing method is typically fastest for primitive data types?





10. Which method is safest for passing large data structures without copying them?





11. In call by reference, what is passed to the function?





12. Which parameter passing method may lead to repeated evaluation of the actual parameter?





13. In call by value-result, when is the copy-back performed?





14. Which parameter passing method is commonly used in C++ for efficiency with large objects?





15. What happens if a function modifies a parameter passed by value?





16. Call by result is similar to:





17. Which parameter passing method is mostly used in functional programming languages?





18. Which of the following methods requires temporary storage to copy back the result?





19. Which method is suitable when you want to pass a constant object to a function?





20. In call by value-result, what happens if the same variable appears twice in the argument list?





21. Which parameter passing method is commonly used in Java?





22. In call by name, the actual parameter is:





23. Which parameter passing method may cause “aliasing” issues?





24. Call by reference is equivalent to:





25. Which method prevents the function from modifying the caller’s variables while avoiding copying large data?





26. Call by value-result can be viewed as a combination of:





27. Which method may produce side effects if the function modifies global objects indirectly?





28. Which method is generally easiest to implement in the compiler?





29. Which parameter passing method is least efficient for large data structures?





30. Why is call by constant reference preferred in C++ for large objects?





Leave a Comment

All copyrights Reserved by MCQsAnswers.com - Powered By T4Tutorials