SyntaxFix
Write A Post
Hire A Developer
Questions
What you're doing is 100% correct.
In terms of nice naming it's often done that private/protected properties are preceded with an underscore to make it obvious that they're not public. E.g. private $_arr = array() or public $arr = array()
private $_arr = array()
public $arr = array()