I have written a function to assign values to a matrix
putConj[arr_, i_, j_, val_] := Block[{},
arr[[i, j]] = val;
arr[[j, i]] = val\[Conjugate];
]
This makes $(i,j)$ and $(j,i)$ entry conjugate (handy for making a Hermitian matrix).
But when I pass an array, I get the General::setps error from the code below
hh = Table[0, 5, 5];
putConj[hh, 1, 2, 5];
General::setps {{0,0,0,0,0},{0,0,0,0,0},{0,0,0,0,0},{0,0,0,0,0},{0,0,0,0,0}} in the part assignment is not a symbol
What I am doing wrong here?