Programming Summative Assessment
Course: Information Technology
Title: Computer Programming
Grade: 12
Topic: Arrays, Files, and Searching
Designed by: Mohammadreza Rahimiangolkhandani (1301459)
Institution: New York Institute of Technology (NYIT)
Professor: Dr. Darren Francis
Date: 2022 - 07 - 02
https://golkhandani.academichosting.ca
“Be the one you love, do what you love.”
Rationale Guiding Questions
- What is the purpose of your assessment?
- Analyze the knowledge and proficiency of the student in working with arrays, files, and
search functions.
- Analyze students’ ability to identify problems and come up with efficient solutions.
- Identify the content (goals/outcomes) to be assessed:
- Problem-solving using arrays, search, and file handling
- Efficiency in solutions
- Familiarity with array techniques and concepts
- Design considerations:
- Rubrics describing ideal performance
- Creative freedom in solution methods
- Clear parameters (length, grading, date, etc.)
- Procedures and Responsibilities:
- Teachers: Tag questions by objectives, blind grading, timely feedback
- Students: Study via feedback, avoid sharing answers
- Supporting student learning:
- Motivates study
- Reveals learning gaps
Assessment Instructions
- No communication between students
- Free choice of IDE
- Exit allowed upon early completion
Part 1: Definitions and Concepts
- Define:
- Space complexity
- Time complexity
- Difference between Map, Set, and List
Part 2: Application
Story: Coffee machine storing customer order data (name, date, price)
- Alphabetically order the data
- Find names starting with M/m
- Customers with at least one item over $2
- Customers spending more than $10 last month
- Group daily data by name and order
Part 3: Code Analysis
fun combinationSum3(k: Int, n: Int): List> {
val result = mutableSetOf>()
fun dfs(i: Int, current: List, sum: Int) {
if (sum == n) {
if (current.size == k){
result.add(current)
}
}
for (j in i..9) {
if (sum + j > n) break
dfs(j + 1, current + j, sum + j)
}
}
dfs(1, emptyList(), 0)
return result.toList()
}
- Calculate time and space complexity
- Rewrite with better time complexity
- Rewrite with better space complexity
References
Download original
file