why is the value being changed even in a const function?
<pre><code>#include&lt;iostream&gt;
using namespace std;

class temp
    {
      int value1; 
      public :
        void fun() const
        {
        ((temp*)this)-&gt;value1 = 10;
        }
        void print()
        {
            cout&lt;&lt;value1&lt;&lt;endl;
        }
     };
int main()
{
  temp t;
  t.fun();
  t.print();
}
</code></pre>
