Given an array, find alternating sum i.e. – y = x (1) – x (2) + x (3) – x (4) + x (5) - …
Solution Stats
Solution Comments
Show comments
Loading...
Problem Recent Solvers54
Suggested Problems
-
Generate a vector like 1,2,2,3,3,3,4,4,4,4
14375 Solvers
-
square a vector-Given the variable x as your input, square it and put the result in y.
112 Solvers
-
1025 Solvers
-
Replace every 3rd element in a vector with 4
268 Solvers
-
326 Solvers
More from this Author30
Problem Tags
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!