#write a loop that calculates 12-factorial
f <- 1:12
for (i in f) 
{
  f <- factorial(i)
}
f
## [1] 479001600