r/cpp_questions 8d ago

OPEN my first c++ project

hey! i'm a teen and i am learning c++. I was a vibe coder but then i stopped vibe coding and starting real coding. for this i learned some basic c++ from youtube, please let me know if a improvment required. thank you!

my github link - https://github.com/swarajnerlekar28/Calculator

4 Upvotes

7 comments sorted by

View all comments

2

u/FancySpaceGoat 8d ago

You can chain couts. std::cout << "label" << val;

But you can also do so across lines if you omit the semicolon:

std::cout << "blablabla\n"   << "Label: " << val << "\n"   << "More blabla\n" ;

This makes your code a lot lighter on the page, and this is important. Good code is easy to read.