Problem 167. Pizza!
Solution Stats
Problem Comments

285 Comments
"Nonscored bonus question: Why is the function interesting?"
 Because the question is in the answer, as long as you do not go for the shortest one.
You can calculate the most value for your money!
This made me laugh more than I care to admit...
Awesome. FWIW, I call foul on the solutions that use Neural Network toolbox  isn't Cody supposed to not use toolboxes?
Why is the function interesting ?
pi_z_z_a ... that's why ... :D
Lol, very nicely done :)
Definitely one of my favorites ;)
PIZZA!!
Kawabanga
You genious :)
Very funny problem with a tasty solution!
made me smile
ha ha ha, soooo funny
Classic!
:)
Nicely apt answer :)
:)
Nice one! I need to go buy the shirt now.
bit tricky
Well served!
Lol that's hilarious... the volume is two pies
pi*z*z*a
Because y = pi*z*z*a
y = pi*z*z*a
pi*z*z*a
y= pi*z*z*a
y = pi*z*z*a
y = pi*z*z*a
y=pi*z*z*a
y = pi*z*z*a
pi*z*z*a
pi*z*z*a!
Nice question! :)
y=pi*z*z*a
y=pi*z*z*a (:
pi*z*z*a
y = pi*z*z*a
V = pi*z*z*a
v=pi*z^2*a
ans = pi*z*z*a
V = pi*z*z*a
y = pi*z*z*a
because the question does not ask for a formula
A = pi*z*z*a
pi*z*z*a
the volume is equal to: pi*z*z*a
ans= pi*z*z*a
pizza = pi*z*z*a
ans= pi*z*z*a
ans= pi*z*z*a
pi*z^2*a
ans= pi*z*z*a
ans= pi*z*z*a
pi*z*z*a
pi*z*z*a
I didn't get what should I insert there to solve it. Could anybody send me the guidelines to dos_lp  at  mail dot ru
Thanks you!
volume = pi .* z .* z .* a;
pi*z*z*a
volume = pi .* z .* z .* a
volume = pi .* z .* z .* a;
why is my solution wrong?
function y = pizza(z,a)
y = pi*z*z*a
end
y = pi*z*z*a
Usually I get the following response:
"No public property version exists for class cody.verifyCode."
but about the tenth time it finally worked.
Not sure what the issue is but it usually bombs on both MS Edge and Chrome browsers.
ti's ok... y = pi*z*z*a; %
pi*z*z*a
v = pi*z*z*a
pi*z*z*a
pi*z*z*a
pi*z*z*a
pi*zz*a
pi*z*z*a
ans=pi*z*z*a
pi*z*z*a
ans=pi*z*z*a
ans=pi*z*z*a
Volume= pi*z*z*a
ans=pi*z*z*a
ans=pi*z*z*a
Volume= pi*z*z*a :)
ans= Pi*z*z*a
A=Pi*z*z*a
How about z*a*a*pi?
Volume = Pi*z*z*a
Volume = Pi*z*z*a
pi*z*z*a!
syms a, z
volume=pi*z^2*a
pi*z*z*a
V_pizza = Pi*z^2*a;
ans=pi*z*z*a
For Pizzas give one = get one
ans=
pi*z^2*a
pizza
Pizza
pi*(z*z)*a
nom nom :)
pizza
Pizza = pi*z*z*a
_
Volume = pi * (z*z)*a
F(z) = pi*(z^2)*a;
pizza=pi*z*z*a.............
pi*z*z*a
ans = pi*z*z*a
pi*z*z*a
pi*z*z*a
delicious= pi*z*z*a;
pi*z*z*a
z*z*a*Pi
z = 1;
a = 1;
v_correct = pi;
assert(isequal(pizza(z,a),v_correct))
pi.z.z.a
Interesting :)
pi*z*z*z
Volume = pi*z*z*a;
pi*z*z*a
Volume = pi*z*z*a
I want some pi*z*z*a
Pi*z*z*a
function [Volume] = findVolume(r,h)
input(radius of pizza is: );
input(thickness of pizza is: );
Volume = pi*r*r*h;
end
% The output "produce" pizza, which got me salivating.
this should be an awesome pi*z*z*a
pi*z*z*a :D
pi*z*z*a :D
V = a*\pi*z^{2}
pi*z*z*a
pi*z*z*a!
pi*z*z*a
pi*z*z*a
pi*z*z*a
F(z)=pi*z*z*a
F(z)=pi*z*z*a
pi*z*z*a
F(z)=pi*z*z*a
pi*z*z*a
pi*z*z*a
Volumeofpizza = pi*z*z*a %This is the volume of a cyclinder (pi*r^2*a)
pi*z*z*a
It's interesting because pi is in pizza and pi*r^2*h is the volume of a cylinder. In this case we are assigning the radius of the pizza with z and the height with a!
pi*z*z*a*
Yummmmm
pizza......nice work!
I am very interested in this Problem.
solution pi*z*z*a
Oww, it is best ...
y=pi*z*z*a
pizza
pi*z*z*a*
pi*z*z*a*
volume = pi*z*z*a
Pi*z*z*a
V = pi*z*z*a
pi*z*z*a
V = pi*z*z*a
V=pi*z*z*a;
*hoho*
V = pi*z*z*a
Could be p*i*z*z*a factorial? (Pizza!)
pizza = pi*z*z*a
I thing that
F = (pi)*(z^2)*a
ans=pi*z*z*a
F = (pi)*(z^2)*a
Pi*zz*a
It is fun as the answer is itself!
%Answer :
function volume = funpizza(z,a)
volume = pi*z*z*a;
end
%Answer:
function volume = funpizza(z,a)
volume = pi*z*z*a;
end
function volume = pizza_volume(z,a) ;
volume = pi*z*z*a;
return;
p*i*z*z*a
function vol = piz(z,a) vol = pi*z*z*a; end
pi*z*z*a!!!
pi*z*z*a
radius=z
th=a
volume=pi*z*z*a
where is my pi*z*z*a
v=pi*z*z*a
ans = pi * z * z * a;
pi*z*z*a
It is fun!
pi*z*z*a
ans= pi*z*z*a
"Pizza!"
pi*z*z*a
ans= pi*z*z*a
Pi*z*z*a
pi*z*z*a
ans = pi * z * z * a
pi * z * z * a
pi*z*z*a
I'm really interested in knowing how to reduce the size of my answer (18).
pi*z*z*a it should be
pi*z*z*a
Pi*z*z*a
pi*z*z*a as it is circular thus, pi*r*r is the area and a is the height/thickness.
pi*z*z*a
F(z)=pi*(z^2)*a;
pi*z*z*a
pi*z*z*a
pi*z*z*a
pi*z*z*a
V = pi*z*z*a
function [V] = pizza(z,a)
V = pi*z*z*a;
end
V = pi*z*z*a
volume = pi*z*z*a;
V=pi*z*z*a
ans = pi*z*z*a
pi*z*z*a
V = pi*z*z*a
ans = pi*(z^2)*a
pi*z^2*a
ans = pi * z * z * a
z = input('Enter the radius of a pizza: ');
a = input('Enter the thickness of a pizza: ');
V=pi*z*z*a
3.14*ztrans(ztrans(a))
ans = pi * z * z * a
V=pi*z*z*a
y = pi*z*z*a
ans = pi*z*z*a
V = pi .* (z .^ 2) .* a;
Volume = pi * z * z * a
ans = pi*z*z*a ..........hahhahahha
Answer:
R=z;
H=a;
V=pi*(R^2)*H;
V = pi .* (z .^ 2) .* a;
V=pi*z^2*a
V=pi*z*z*a
V=pi*z*z*a;
V=pi*z^2*a
V=pi*z*z*a
funtction [V] = pizza_volume(z,a)
V=pi*z^2*a;
end
Funny!!!
y=pi*z^2*a
y= pi*z^2*a
V = pi*z*z*a
y=pi*z^2*a
indeed.
Easy
this's funny
easy
i like these basic questions, they dont really require you to go through the manuals and basic.
interesting question
yay
so i need a piz2a now
good one
nice
nice
Pretty tricky and funny. haha, XD
lol very easy
:)
That was a tough one
nice
My favorite food is pi*z*z*a
Very funny problem!
nice
volum=f(z,a)=(pi*z^2*a)
Tasty solution!!
Pizza!
Just trying to get points...
Doing this for a grade in class.
(Y)
ha ha ha. r become z and h become a.
Very simple and useful example.
great problem!
Haha! Good one!
how to reduce size from 18 to 10?
Nice!!
Just love this one:)
pizza pi! Yum
Took me time to get the joke, since I started with a rounded edge pizza instead of a cylinder.
I got:
Volume = (a*pi*((a/2  z)^2 + 2*z^2))/3
Technically more accurate, but clearly not as funny as the intended result...
(I suck at math so I had to Google the volume of a barrel shape, and constrain it to : rounding radius = thickness/2, and let the solve function do the algebra for me...)
PIzza
yeah! pi*a*z^2
pi*z^2*a
Ten points for the pun, that's *bad*. ;)
nice
Very Nice Question!
Fun Question and Solution!
ahah nice one
It's a funny question
good
nice problem!!
Great!!!
nice
haha funny one!
The name is the solution!
good!
jajajaja. Now do the same with hamburgers.
Pizza!!!!!!
funny
Fun
Love the problem name!
Didn't see that coming ahah
nice
nice name
Nice One :)
Good problem
cool problem
classic
pi * z *z *a = pizza
Solution Comments

1 Comment
fun :)

1 Comment
good

1 Comment
It is interesting because it is thick pi z*z a pie.

2 Comments
it is easy
i want another problem like this one

1 Comment
Oh my, I got it just now :)

1 Comment
the solution is in the name...funny

2 Comments
nice
nice

1 Comment
wowda

1 Comment
Love the name of the function Pizza. Once solved it makes sense ;)

2 Comments

1 Comment
good job

1 Comment
nice

1 Comment
ez

1 Comment
nice and easy

5 Comments
V = pi .* (z .^ 2) .* a;
V=pi*z^2*a
function [V] = pizza_volume (z, a)
V = pi*a*z^2;
end
y=pi*z^2*a
good solution

1 Comment
This user (mohamed elbesealy) appears to have gamed the system, with fraudulent "likes" of this unremarkable solution submitted by 'sockpuppet' accounts. —DIV

23 Comments
It is fun because the volume is pizza!
function vol = piz(z,a)
return pi*z*z*a;
function vol = piz(z,a) return pi*z*z*a;
pi*z*z*a
pi*z*z*a
pi*z*z*a
pi*z*z*a
pi*z*z*a
pi*z*z*a
ans = pi * z * z * a
pi*z*z*a
pi*z*z*a
V= pi*z*z*a
ans = pi * z * z * a
pi*z*z*a
V = pi*z*z*a
V=pi*z*z*a
pi*z*z*a
ans = pi*z*z*as
Volume = pi * z * z * a
Volume = pi * z * z * a
pi*z*z*a = Volume
Hi PI*Z*Z*A

4 Comments
Not sure how this works.... such a head ache QQ
Answer is : "ans = pi * z * z * a"
ans = pi * z * z * a
ans = pi*z*z*a

1 Comment
pi*z*z*a*

5 Comments
How to reduce it?
Awesome pi*z*z*a
This is an awesome pi*z*z*a
V = a*π*z^{2}
I'm not sure I did this right...
pi*z*z*a

5 Comments
This function pizza gives its volume which is also it's name.
F(z) = pi*(z^2)*a;
delicious= pi*z*z*a;
this should be an awesome pi*z*z*a
ometimes “pizza” can be a formula and a food (number 13 makes everyone smile)

5 Comments
p*i*z*z*a is angry
p*i*z*z*a
Good one! Pi*zz*a is the answer.
Pi*z^2*a
p*i*z*z*a

1 Comment
The name "pizza" says it all.

2 Comments
give a pizza to get a pizza
ans=pi*z*z*a

1 Comment
its pizza that's why

1 Comment
This is a fun spelling joke!

5 Comments
Cody seems to not accept anonymous functions, despite code is shorter.
ans= pi*z*z*a
ans=pi*z*z*a
z*z*a*pi
z*z=d
Pi=3.1415926...
ans=Pi*z*z*a

3 Comments
y = a*z*z*3.14123fd222234gh
ans = pi*z*z*a
A = pi*z*z*a

1 Comment
Very smart use of parameter names. pi*z*z*a

1 Comment
because pizza!

1 Comment
Because the solution can be spelled
like pizza, pi*z*z*a !!!

1 Comment
;) now I get it...

1 Comment
because y = pi*z*z*a;

1 Comment
Wow

2 Comments
How can one get this code any shorter???
You can for example use ans instead of y to store the result.

2 Comments
Why is this a leading solution? The complexity is higher than a simple "pi * z * z * a".
How is it size 10?? I still get 18, and it is just pi*z^2*a

1 Comment
cylinder size = pi*radius^2*hieght

1 Comment
haha

1 Comment
hmmm

1 Comment
question is very simple need more

2 Comments
pi*z*z*a
that is why it is called 'pizza'
good job!

1 Comment
I have no idea on this regular expression. Could you explain what is happening here?

1 Comment
Haha...interesting!

2 Comments
Good Solutions!
nice

6 Comments
Hahahaha
muito boa!
hahahahahahaha now I understand why it's so interesting
Nice design:)
pi*z*z*a
pi*z*z*a
Problem Recent Solvers19347
Suggested Problems

Remove the small words from a list of words.
1016 Solvers

given 3 sides, find area of this triangle
741 Solvers

748 Solvers

325 Solvers

613 Solvers
More from this Author23
Problem Tags
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!