FOIL:
Sum of
#color(white)("XXX")#product of First terms, plus
#color(white)("XXX")#product of Outside terms, plus
#color(white)("XXX")#product of Inside terms, plus
#color(white)("XXX")#product of Last terms
#{:
("product of First terms", 9x*3x=, 27x^2),
("product of Outside terms",9x*3=,27x),
("product of Inside terms", 9*3x =, 27x),
("product of Last terms", 9*3=,27),
(, ,),
("Sum", ,27x^2+54x+27)
:}#