You need to carefully pick the right brackets () or {}. You can define an algorithm with both of the brackets, the difference is that () does not capture the parameter, but {} captures the parameter which is used inside the brackets.
When You define a property, then property body is automatically interpreted as defined in {} brackets.