Problem 44943. Calculate Amount of Cake Frosting
Given two input variables r and h, which stand for the radius and height of a cake, calculate the surface area of the cake you need to put frosting on (all around the sides and the top).
Return the result in output variable SA.
Solution Stats
Problem Comments
-
16 Comments
Show
13 older comments
Maya Ben Yacov
on 17 Oct 2023
I used the cylinder surface area formula: 2*pi*r(r+h)
am I using the wrong formula?
Christian Schröder
on 18 Oct 2023
@Maya Ben Yacov It's the right formula in principle, but keep in mind that the bottom of the cake does not get frosting.
Miron Krejci
on 5 Mar 2024
Tasty problem
Solution Comments
Show commentsGroup

Teaching IT - Programmierpraxis
- 25 Problems
- 9 Finishers
- Find the Oldest Person in a Room
- Convert from Fahrenheit to Celsius
- Select every other element of a vector
- Calculate the Number of Sign Changes in a Row Vector (No Element Is Zero)
- Check if number exists in vector
- Generate a vector like 1,2,2,3,3,3,4,4,4,4
- Convert a Cell Array into an Array
- Cell Counting: How Many Draws?
- Doubling elements in a vector
- Symmetry of vector
- Return area of square
- Calculate Amount of Cake Frosting
- Flip the vector from right to left
- Determine the number of odd integers in a vector
- Make an awesome ramp for a tiny motorcycle stuntman
- Cell joiner
- Fix the last element of a cell array
- Oh Zero Zero Zero!!!
- Plot Damped Sinusoid
- frame of the matrix
- Solve a System of Linear Equations
- Replace Nonzero Numbers with 1
- Remove entire row and column in the matrix containing the input values
- Find the maximum number of decimal places in a set of numbers
- subtract central cross
Problem Recent Solvers26297
Problem Tags
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!