fork download
  1. x=[2 3 4 5 -2 -3 5 0];
  2. y = ~mod(x,2);
  3. x(y) = x(y) * 5
  4. %x(rem(x,2)==0) = 5*x(rem(x,2)==0)
Success #stdin #stdout 0.17s 65056KB
stdin
Standard input is empty
stdout
x =

   10    3   20    5  -10   -3    5    0