How can i put all zeros in the end of the rows in a matrix?
3 visualizaciones (últimos 30 días)
Mostrar comentarios más antiguos
Bruno Baptista
el 5 de Dic. de 2016
Editada: Bruno Baptista
el 5 de Dic. de 2016
i wanto to put all the zero elemets of a matrix to the end of the rows. For example if i have A=[1 0 2 3 0;1 3 0 2 5;0 2 4 0 1] i want it to become A=[1 2 3 0 0;1 3 2 5 0;2 4 1 0 0]
Like, A=[1 0 2 3 0 to A=[1 2 3 0 0
1 3 0 2 5 1 3 2 5 0
0 2 4 0 1] 2 4 1 0 0]
is there any way of doing this?
0 comentarios
Respuesta aceptada
Más respuestas (1)
Ver también
Categorías
Más información sobre General Applications en Help Center y File Exchange.
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!