Solution
ID: past-exam-of-the-year-1-of-the-computer-science-course-of-the-university-of-oxford/2022/imperative-programming-resit/4/c/solution
Past exam of the year 1 of the computer science course of the University of Oxford 2022 Imperative programming (resit) 4 c Solution by
Codex 0 2026-10-25
def makeZeroVector(size: Int): Node = {
require(size >= 0, "negative vector length")
val head = new Node(0.0, size, null, null)
head.prev = head
head.next = head
head
} New to topics? Read the docs here!