passing arrays to methods constructors