Files
charlie 877acb5a8f feat: Add JavaScript core exercises and solutions
- Implemented exercises for array high-order methods, memory and execution, switch statements, and final review.
- Added starter and answer files for each exercise to facilitate learning.
- Created a runner HTML file to execute JavaScript code and display console outputs.
- Updated README files to include exercise objectives, tasks, and usage instructions.
2026-03-13 11:09:19 +08:00

750 B
Raw Permalink Blame History

练习 14内存和执行

目标

理解“值”和“引用”的区别,以及函数执行时数据为什么会变化。

你要练什么

  • 基本类型复制
  • 引用类型共享
  • 函数执行顺序
  • 参数传递

任务

请完成一个“数据变化观察”脚本,要求:

  • 比较基本类型复制后是否互相影响
  • 比较对象复制后是否互相影响
  • 写两个函数观察执行顺序
  • 写一个函数修改传入对象,观察外部对象为什么会变化

文件