SyntaxFix
Write A Post
Hire A Developer
Questions
A bit more along the same lines
attrs <- {} attrs.a <- 1 f <- function(d) { attrs.a <- d } f(20) print(attrs.a)
will print "1"
attrs <- {} attrs.a <- 1 f <- function(d) { attrs.a <<- d } f(20) print(attrs.a)
Will print "20"