Error in unit2_exercise compiled

I have an error compiled on the unit2_exercise, Can I get some idea ?

Hi @Ricoder007

When you compile a file that it’s using components of ros and c++ you need to make:

           rosrun <package_name> <executable_name>

In your case will be:

           rosrun c_scripts unit2_exercise

Finally, don’t forget compile your work_space.

These would be the steps:

cd ~/catkin_ws
catkin_make
source devel/setup.bash
rosrun c_scripts unit2_exercise

Let me know if it solves your problem

Regards,
Ruben

Thanks to the Answers… The Scripts is running well…

Hi @Ricoder007

Do not forget to give “resolved” to the comment that solves your problem, so that the topic is closed.

Regards,
Ruben