0:n
returns the vector c(0, 1, 2, ..., n)
and 4*0:n
will multiply each element by 4 to yield c(0, 4, 8, ..., 4n)
. So, this gives a vector in which the difference between each element is 4. It does not give a vector of four equally spaced elements except in the case that n
is 3.
solved what is the result of 4*0:g_range[2]? [closed]