Problem 1630. ~~~~~~~ WAVE ~~~~~~~~~
The WAVE generator
Once upon a time there was a river. 'Sum' was passing by the river. He saw the water of the river that was so still and clear as crystal. He threw a stone into river. Then again he threw another stone of higher weight into the river.He saw there was two different kinds of waves were being generated due to the difference in weight of the stone.
For EXAMPLE: 'Sum' threw a stone of weight 6. The river generated wave as bellow.
1 1 1 1 1 1 1 2 2 2 2 2 1 2 3 3 3 3 1 2 3 4 4 4 1 2 3 4 5 5 1 2 3 4 5 6
Solution Stats
Problem Comments
-
1 Comment
Fun !
Solution Comments
Show commentsProblem Recent Solvers343
Suggested Problems
-
4351 Solvers
-
Project Euler: Problem 6, Natural numbers, squares and sums.
2312 Solvers
-
Return unique values without sorting
934 Solvers
-
middleAsColumn: Return all but first and last element as a column vector
611 Solvers
-
724 Solvers
More from this Author16
Problem Tags
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!