Welcome to the Treehouse Community

Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community! While you're at it, check out some resources Treehouse students have shared here.

Looking to learn something new?

Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.

Start your free trial


Create a float variable named 'radius' with the value '14.5'.

include <stdio.h>

int main() { float radius = 14.5; printf ("%f is a radius.\n", radius); return 0; } I dont understand whats wrong with this.. Plssss help. sorry

4 Answers

Gary Luce
Gary Luce
7,153 Points

you are not asked to include the int main or a return statement.

Everything else is fine. Also make sure the text is correct and it should work.

float radius = 14.5;

printf ("%f is a radius.\n", radius);

Thank you so much Andrew, it has been a great help. So relieve now ;)

I have taken out the #include, int main and return statement but it seems the same.

float radius = 14.5;

printf("A ball with a radius of %f inches", radius );

assuming you are doing the associated task the above will work hope that helps.