Homework 03 Solutions Fall 2014
First-page document preview for Homework 03 Solutions Fall 2014 in ECE 449: Object-Oriented Programming and Computer Simulation at Illinois Institute of Technology (IIT). Inspect the first page below or request the complete PDF study document for free.
Independent study archive Learn more
Materials are uploaded by users for self-study purposes. PwnHero is an independent platform, not affiliated with, sponsored by, or endorsed by any university or institution.
University
Illinois Institute of Technology (IIT)
Course
ECE 449: Object-Oriented Programming and Computer Simulation
Format
Homework
Year
2014
📄 Page 1 Preview
Page 1 Key Topics & Excerpt
🔍 Text Transcript
First page excerpt for quick study reference. Complete formulas, diagrams, and subsequent pages are available in the full document.
PwnHero
Homework 03 Solutions
ECE 449, Fall 2014
1. (5 points) Review the following pieces of code and briefly explain potential issues.
A. void test(std::vector<int> &v) {
for (size_t i = 0; i < 100; ++i) {
v[i] = i;
}
}
Answer: v[i] is undefined when v contains less than 100 elements.
B.…