Passing Parameters Introduction - C++ vs Python

preview_player
Показать описание
Python doesn't pass variables in the same way as many other languages. This is the introduction to a course which dives much deeper into "Pass by Reference in Python: Best Practices". Covered here are examples of passing values in C++ and an overview of the full course.

Рекомендации по теме
Комментарии
Автор

10:11 Bad example, "a[]" is the same as "* a", where a is a pointer (i.e. a variable holding an address) to the first element of the array. So passing it by value is not an issue since only the address is copied (and if you don't want the array to be modified, you should use "double const a[]").

Baha
Автор

Id you could do something on multithreading vs multiprocessing one day. I’m having issues with that.

dopy