Problem 42800. house of cards
How many cards do one need to build a house of cards with n stages? Short explanation:
/\ 2 cards for 1 stage
/_\ 7 cards for 2 stages /\ /\
....
Solution Stats
Problem Comments
-
2 Comments
Jan Orwat
on 15 Apr 2016
@Thomas, the Test Suite is broken. Please provide "x" or replace it with "n" in tests.
Thomas Bischoff
on 15 Apr 2016
Sorry for mistake! You are right! thanks
Solution Comments
Show commentsProblem Recent Solvers36
Suggested Problems
-
Select every other element of a vector
35043 Solvers
-
Back to basics 11 - Max Integer
798 Solvers
-
Matrix indexing with two vectors of indices
751 Solvers
-
Calculate the area of a triangle between three points
3274 Solvers
-
Find out total non zero element of matrix
277 Solvers
More from this Author9
Problem Tags
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!