In[2]:= f[x_,y_] := x^2 y In[3]:= f[2,3] Out[3]= 12 In[6]:= g[x_] := f[x,x] In[7]:= f[x_] := f[x,x] In[8]:= f[3] Out[8]= 27 In[9]:= g[3] Out[9]= 27 In[10]:= doTwice[func_,input_] := func[func[input]] In[11]:= doTwice[f,3] Out[11]= 19683 In[12]:= f[x] == x^3 Out[12]= True In[16]:= a+b == b+a Out[16]= True In[18]:= doTwice[f,x] Out[18]= x^9 In[19]:= doTwice[f,x] == x^9 Out[19]= True