difference between function and marco
Anónimo
A function is compiled and type-checked, so it's safer and easier to debug. A macro is a preprocessor directive that just replaces code before compilation—it's faster but doesn't check types and can lead to errors if not used carefully.