typeover
curriculum

Curriculum Collections Maps exercise 6 · fill-word

Maps

Translate Object.keys(${name}).length to Go. The builtin you want is the SAME ONE you've already used on slices and strings — Go uniforms length across these three shapes under one name.

TypeScript reference
Fill the blanks →

About this theme

map[K]V. Like a TS Record<K, V> or Map<K, V>. Lookup with comma-ok: v, ok := m[key]. Iteration order is undefined — every range yields a different ordering. Maps are reference types; passing a map to a function shares it.