q. WAP to implement the use of scope resolution operator

int number=100;
int main()
coute block\n";
int number=555;
return 0;

output of the program:
in main
inside block
number=555 ::number=555
back in main
number=234 ::number=234

Description about program:

in the above programe firstly we declared globally number to100. Then in the main fuction we firstly define that we are in main then define an integer type number =243 . then inside an another block we again define an integer type number=555. Then if we simply write cout number in side that block it show an output number=555. outside the block if we write cout

Written by
Love Is Life...... Love Is A Flame That's light Up The Soule....

People in this conversation

We are one community

Boddunan.com is a community driven articles and knowledge sharing portal. Members can share their knowledge with other members and visitors of the website and make them-self popular in the massive Internet world.

Boddunan.com is used not only as a platform to share the content and knowledge, but also a useful tool to learn from the vast amount of knowledge shared by thousands of registered users of the website. The content directory is a host of all the articles posted by the community and is available for the visitors of boddunan.com to read and learn from the extensive knowledge,