0
0
C++programming~15 mins

What is C++ - Hands-On Activity

Choose your learning style9 modes available
What is C++
📖 Scenario: Imagine you want to learn about a popular programming language called C++. It is used to create many types of software, from games to operating systems.
🎯 Goal: You will write a simple C++ program that shows a message explaining what C++ is.
📋 What You'll Learn
Create a string variable called description with the exact text: "C++ is a powerful programming language used for system and application software."
Create an integer variable called yearCreated and set it to 1985
Print the description variable
Print the text: "It was created in " followed by the yearCreated variable
💡 Why This Matters
🌍 Real World
C++ is used to build fast and efficient software like games, browsers, and operating systems.
💼 Career
Knowing C++ opens opportunities in software development, game programming, and systems engineering.
Progress0 / 4 steps
1
DATA SETUP: Create the description variable
Create a string variable called description and set it to "C++ is a powerful programming language used for system and application software."
C++
Need a hint?

Use std::string to create a text variable and assign the exact sentence inside double quotes.

2
CONFIGURATION: Create the yearCreated variable
Create an integer variable called yearCreated and set it to 1985
C++
Need a hint?

Use int to create a number variable and assign it the value 1985.

3
CORE LOGIC: Print the description and yearCreated
Use std::cout to print the description variable, then print the text "It was created in " followed by the yearCreated variable.
C++
Need a hint?

Use std::cout with the insertion operator << to print text and variables. End lines with std::endl.

4
OUTPUT: Run the program to see the message
Run the program and observe the output. It should first show the description text, then the creation year message.
C++
Need a hint?

Make sure your program prints exactly the two lines as shown.