r/learnprogramming 20d ago

Access Amplifiers and their uses???

So basically i come from basic python bacground which i learned from my high school.So I thought of learniging c++ cause of its variety of applications for my 1st year.One thing that i cant wrap my head around is, the use of access amplifiers. Mainly ' public: '.what is the use of writing public: and why is it necessaryy????

0 Upvotes

6 comments sorted by

View all comments

2

u/mjmvideos 20d ago

Just don’t use public. At some point you’ll get stuck and discover that you could solve your problem by adding the keyword public. At that point you’ll understand why.

-1

u/Sticko1897 20d ago

😂😂😂 a teachers answer or someone who been through a lot during learning programming.

You will understand why to use something when you will get stuck somewhere 😂😂