proc test(foo: seq[string], bar: int64) =
for i in 0..<min(len(foo), bar):
stdout.write(foo[i])
aW1wb3J0IHN5c3RlbQoKcHJvYyB0ZXN0KGZvbzogc2VxW3N0cmluZ10sIGJhcjogaW50NjQpID0KICBmb3IgaSBpbiAwLi48bWluKGxlbihmb28pLCBiYXIpOgogICAgc3Rkb3V0LndyaXRlKGZvb1tpXSkK
prog.nim(5, 21) Error: type mismatch: got (seq[string], int64)
but expected one of:
proc `[]`[Idx, T](a: array[Idx, T]; x: Slice[Idx]): seq[T]
proc `[]`(s: string; x: Slice[int]): string
proc `[]`[T](s: seq[T]; x: Slice[int]): seq[T]
proc `[]`[I: Ordinal, T](a: T; i: I): T
proc `[]`[Idx, T](a: array[Idx, T]; x: Slice[int]): seq[T]