MATLAB: Splitting a vector into two independent vectors

modifying vectorssplitting vectors

Hello all! I have a vector suppose v having length of m. Now how can I split a vector into two new vectors, say w and y. Lets say I have to split the vector v at row number n.
order of v =(m,1)
order of w =(n,1)
order of y =((m-n),1)
here
m is the total number of rows of parent vector v
n is the total number of rows of new vector w
m-n is the number of rows of new vector y
Thank you!

Best Answer

w=v(1:n);
y=v(n+1:end);