Java Create New Array With Condition