Programming Magic...!!!
As a lifelong learner, I stay up-to-date with the latest technologies and trends, ensuring that my work reflects cutting-edge practices and delivers exceptional results.
when we write this code in C++ or any other programming languages
int num=0647;
cout<<num<<endl;
output:->423

output:-

In the provided code, we declare an integer variable num and assigned it the value 0647. However, it's important to note that when a number starts with a leading zero (0) in C++ (and many other programming languages), it is interpreted as an octal (base 8) number, rather than a decimal (base 10) number.
So, 0647 is treated as an octal number, which is equivalent to 423 in decimal notation.