title: Quadratic equation solver outputting in unknown format
body: <p>I'm trying to make a quadratic equation solver, but for some reason my program is giving me answers in an unknown format.</p>
  
  <p>I entered the simple quadratic equation x^2 + 2x + 1 = 0, expecting my program to give x = -1 or x = -1, but instead it gave x = 0138151E or x = 0138152D. It looks like it outputs these values for x for any inputs (not recognizing unreal answers and catching them). Why is this and how can I fix it?</p>
  
  <pre><code>#include "../std_lib_facilities_revised.h"
  
  class Imaginary {};
  
  double square(int a)
  {
      return a * a;
  }
  
  double quadratic_solver_pos(int a, int b, int c)
  {
      double x = 0.0;
      double radicand = square(b) - 4 * a * c;
      if (radicand &lt; 0) throw Imaginary{};
      x = (-b + sqrt(radicand)) / (2 * a);
      return x;
  }
  
  double quadratic_solver_neg(int a, int b, int c)
  {
      double x = 0.0;
      double radicand = square(b) - 4 * a * c;
      if (radicand &lt; 0) throw Imaginary{};
      x = (-b - sqrt(radicand)) / (2 * a);
      return x;
  }
  
  int main()
  try {
      cout &lt;&lt; "This program is a quadratic equation solver.\n";
      cout &lt;&lt; "Quadratic equations are of the form: ax^2 + bx + c = 0\n";
      cout &lt;&lt; "Enter a, b, and c, respectively:\n";
      double a = 0; 
      double b = 0;
      double c = 0;
      cin &gt;&gt; a &gt;&gt; b &gt;&gt; c;
      cout &lt;&lt; "Your quadratic equation: " &lt;&lt; a &lt;&lt; "x^2 + " &lt;&lt; b &lt;&lt; "x + " &lt;&lt; c &lt;&lt; " = 0\n";
      cout &lt;&lt; "x = " &lt;&lt; quadratic_solver_pos &lt;&lt; " or x = " &lt;&lt; quadratic_solver_neg &lt;&lt; '\n';
  }
  catch (Imaginary) {
      cout &lt;&lt; "x is unreal\n";
  }
  </code></pre>