Always use use strict. Try to use use warningsas often as possible.
Since use strictyour test script will not even start, Perl will display the following error messages:
Bareword "name" not allowed while "strict subs" in use at test.pl line 8.
Bareword "id" not allowed while "strict subs" in use at test.pl line 9.
Bareword "address" not allowed while "strict subs" in use at test.pl line 10.
Execution of test.pl aborted due to compilation errors.
This is because the names of your array indices are visible only to your TestArrayObject module, and not to the test script.
-, , get_name/set_name, .