1 2 3 4 5 6 7 8 9 10 11
proc derivative(x, n) { for $i in 1..(n+1) { id x^m? = m? * x^(m? - 1); } } expr F = u^5; apply { call derivative(u, 2); }