Consider the following expression: . Let us expand it first and then shrink back to its original form.

This is how we do this in Maxima:

The colon,

In Mathematica, the assignment operator is `=`, whereas, as you should
now be able to recall, `:=` is a delayed evaluation assignment operator.
Mathematica's equivalents of `expand` and `factor` are
`Expand` and `Factor`: