mirror of
https://github.com/nim-lang/Nim.git
synced 2025-12-29 17:34:43 +00:00
19 lines
291 B
Nim
19 lines
291 B
Nim
discard """
|
|
output: '''13 abc'''
|
|
"""
|
|
|
|
type
|
|
PBinaryTree = ref object
|
|
le, ri: PBinaryTree
|
|
value: int
|
|
|
|
|
|
proc main =
|
|
var x: PBinaryTree
|
|
deepCopy(x, PBinaryTree(ri: PBinaryTree(le: PBinaryTree(value: 13))))
|
|
var y: string
|
|
deepCopy y, "abc"
|
|
echo x.ri.le.value, " ", y
|
|
|
|
main()
|