summary refs log blame commit diff stats
path: root/tests/accept/run/tvartup.nim
blob: f885cdf373e5791777e331160a3319c44fb0f9cd (plain) (tree)
1
2
3
4



                     










                                            

 
discard """
  file: "tvartup.nim"
  output: "2 3"
"""
# Test the new tuple unpacking

proc divmod(a, b: int): tuple[di, mo: int] =
  return (a div b, a mod b)
  
var (x, y) = divmod(15, 6)
stdout.write(x)
stdout.write(" ")
stdout.write(y)

#OUT 2 3