Welcome to the Treehouse Community
The Treehouse Community is a meeting place for developers, designers, and programmers of all backgrounds and skill levels to get support. Collaborate here on code errors or bugs that you need feedback on, or asking for an extra set of eyes on your latest project. Join thousands of Treehouse students and alumni in the community today. (Note: Only Treehouse students can comment or ask questions, but non-students are welcome to browse our conversations.)
Looking to learn something new?
Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and a supportive community. Start your free trial today.
Ashley Wong
209 PointsVariable_Assignment part 2 Float Variable
I am supposed to make a printf statement for the float variable radius. I wrote: printf ("%f radius.\n", 'radius'); Please help! I don't know what I did wrong.
4 Answers

kerdeseverin
9,688 PointsI think its because you have ' ' around radius. Shouldn't it be:
printf ("%f radius.\n", radius);
Ashley Wong
209 PointsI tried that also, it didn't work. The challenge told me that I was wrong

kerdeseverin
9,688 PointsOkay so I checked the challenge. It says Here is what your output should look like: " A ball with a radius of 14.5 inches."
float radius = 14.5;
printf("A ball with a radius of %f inches",radius);
Ashley Wong
209 PointsI literally copied and pasted your response but it was still incorrect.

kerdeseverin
9,688 PointsSorry I edited my answer, didn't realize I had an @ symbol. Habit.