Previous Lecture | lect09 Before Slides | lect09 Annotated Slides | Next Lecture |
Topics
Code from lecture
https://github.com/ucsb-cs16-s18-mirza/cs16-s18-lectures/tree/master/lec-09
Pointers
- Pointer declaration - difference/similarities with declaring basic types
- Accessing variables “indirectly” via pointers
- The address and indirection operators: “&” and “*”
- Pointers and arrays - similarities and dfferences
- Passing arrays to functions - specifically looking at how arrays degnerate to pointers on function calls.
Under the hood of function calls
- Function calls use the run-time stack, we’ll see how and why that’s important
- Review of pass by value
- Passing parameters to functions by address