From the course: C Essential Training

Unlock the full course today

Join today to access over 22,600 courses taught by industry experts or purchase this course individually.

Challenge: Write your own code

Challenge: Write your own code - C Tutorial

From the course: C Essential Training

Start my 1-month free trial

Challenge: Write your own code

(upbeat music) - [Narrator] Here is your challenge to see how well you understand C programming so far. Yes, you can do this. Create a source code file with the main function, include a statement that outputs text. If you can, write this code from scratch. Don't use any exercise file or the preset code provided from your IDE. You can use the command prompt, or the IDE, or both if you want a real challenge. As a hint, use the puts function to generate text output. Enclose the output text, the string literal, in double quotes as the puts functions argument. If you really need help peek at the exercise file. 0104, sample C, though only do this as a last resort. As a bonus challenge, write another version of the program that outputs two lines of text by adding a second put statement. This exercise should take you about five minutes to complete.

Contents