\( \definecolor{colordef}{RGB}{249,49,84} \definecolor{colorprop}{RGB}{18,102,241} \)
Consider the following calculation program:
  1. Choose a number.
  2. Divide by \(2\).
  3. Add \(2\).
Let \(x\) be the chosen number. Find the function that gives the output of this program.
\(f(x) =\)