added print mean for arrays