Implement Prototype(text, pattern string) []int by trying each rune start; Solve must use KMP O(n+m) time and O(m) auxiliary space. Return all ascending rune indices, including overlaps. Empty pattern matches all rune boundaries, including the end. Exact code-point equality; preserve text without folding or normalization. Unlike Go's byte-index string search APIs, this contract deliberately uses rune positions.

Edit exercise.go; retain the public types and signatures. prototype and final are separate stages. The executable tests recover panics as failures, report named checks, and exit nonzero on any failure. A successful run must execute at least one check. Tests use logical time or explicit synchronization where relevant.

Drag or use the arrow keys to resize. Home collapses the question; End collapses the editor. Enter or double-click resets the split.
Loading editor…
No results yet.

Complete the starter code, then run the checks.
Results and errors will appear here.