adjusted set and array literal

we suppose set is used less than array. type signature
is also tweeked a little to give it a type parameter
flavor to create arrays.