Error : "No match for 'operator <<' (operand types are std::istream)
<p>This is my first StackOverflow and happy to join.
I'm currently studying C++ with Stroustrup's "Programming and Practice using C++" and for now we are using a library he created (#include "std_lib_facilities.h")</p>

<p>I finished an exercise and got this error
"No match for 'operator &lt;&lt;' (operand types are std::istream)"</p>

<p>The program I wrote may not be perfect yet but I can't even compile it at this point. I've read in other posts something about "overload operator" but I don't understand what it means and specifically why in my other files this does not happen even with the same library loaded.</p>

<pre><code>#include "../../std_lib_facilities.h"

int main()
{
    double val1 = 0;
    double val2 = 0;

    cin &lt;&lt; val1 &lt;&lt; val2 &lt;&lt; endl;

    if (val1&gt;val2)
        cout &lt;&lt; val1 &lt;&lt; " is larger than " &lt;&lt; val2 &lt;&lt;endl;
    else
        cout &lt;&lt; val1 &lt;&lt; " is smaller than " &lt;&lt; val2 &lt;&lt;endl;
</code></pre>

<p>}</p>