Write a function that takes as input a vector x and uses a for loop to calculate the sum of the vector x. It should output the sum of the vector.
    8 visualizaciones (últimos 30 días)
  
       Mostrar comentarios más antiguos
    
I have no idea what to do and I'm not allowed to use built-in matlab functions
2 comentarios
  Stephen23
      
      
 el 7 de Feb. de 2020
				Start by doing these tutorials:
Most of what you need to know is contained in them.
Respuestas (1)
  royed
 el 7 de Feb. de 2020
        In principle I shouldn't answer the question.
1) Define Array
2) for loop indexing the elements of the array till ir reaches the last element 
0 comentarios
Ver también
Categorías
				Más información sobre Loops and Conditional Statements 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!



