<?xml version="1.0"?>
<?xml-stylesheet type="text/css" href="http://programmingexamples.net/w/skins/common/feed.css?303"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
		<id>http://programmingexamples.net/w/index.php?action=history&amp;feed=atom&amp;title=CPP%2FMath%2FMinMax</id>
		<title>CPP/Math/MinMax - Revision history</title>
		<link rel="self" type="application/atom+xml" href="http://programmingexamples.net/w/index.php?action=history&amp;feed=atom&amp;title=CPP%2FMath%2FMinMax"/>
		<link rel="alternate" type="text/html" href="http://programmingexamples.net/w/index.php?title=CPP/Math/MinMax&amp;action=history"/>
		<updated>2026-04-18T00:09:58Z</updated>
		<subtitle>Revision history for this page on the wiki</subtitle>
		<generator>MediaWiki 1.23.5</generator>

	<entry>
		<id>http://programmingexamples.net/w/index.php?title=CPP/Math/MinMax&amp;diff=88&amp;oldid=prev</id>
		<title>Daviddoria: Created page with '==MinMax.cpp== &lt;source lang=&quot;cpp&quot;&gt; #include &lt;iostream&gt; #include &lt;cmath&gt;  int main(int argc, char *argv[]) {    {   double a = 10.3;   double b = 5.8;    std::cout &lt;&lt; &quot;Min: &quot; &lt;&lt; s…'</title>
		<link rel="alternate" type="text/html" href="http://programmingexamples.net/w/index.php?title=CPP/Math/MinMax&amp;diff=88&amp;oldid=prev"/>
				<updated>2010-06-23T12:42:22Z</updated>
		
		<summary type="html">&lt;p&gt;Created page with &amp;#039;==MinMax.cpp== &amp;lt;source lang=&amp;quot;cpp&amp;quot;&amp;gt; #include &amp;lt;iostream&amp;gt; #include &amp;lt;cmath&amp;gt;  int main(int argc, char *argv[]) {    {   double a = 10.3;   double b = 5.8;    std::cout &amp;lt;&amp;lt; &amp;quot;Min: &amp;quot; &amp;lt;&amp;lt; s…&amp;#039;&lt;/p&gt;
&lt;p&gt;&lt;b&gt;New page&lt;/b&gt;&lt;/p&gt;&lt;div&gt;==MinMax.cpp==&lt;br /&gt;
&amp;lt;source lang=&amp;quot;cpp&amp;quot;&amp;gt;&lt;br /&gt;
#include &amp;lt;iostream&amp;gt;&lt;br /&gt;
#include &amp;lt;cmath&amp;gt;&lt;br /&gt;
&lt;br /&gt;
int main(int argc, char *argv[])&lt;br /&gt;
{&lt;br /&gt;
&lt;br /&gt;
  {&lt;br /&gt;
  double a = 10.3;&lt;br /&gt;
  double b = 5.8;&lt;br /&gt;
&lt;br /&gt;
  std::cout &amp;lt;&amp;lt; &amp;quot;Min: &amp;quot; &amp;lt;&amp;lt; std::min(a,b) &amp;lt;&amp;lt; std::endl;&lt;br /&gt;
  std::cout &amp;lt;&amp;lt; &amp;quot;Max: &amp;quot; &amp;lt;&amp;lt; std::max(a,b) &amp;lt;&amp;lt; std::endl;&lt;br /&gt;
  }&lt;br /&gt;
  &lt;br /&gt;
  //doesn't work&lt;br /&gt;
  /*&lt;br /&gt;
  {&lt;br /&gt;
  double a = 10.3;&lt;br /&gt;
  int b = 5;&lt;br /&gt;
&lt;br /&gt;
  std::cout &amp;lt;&amp;lt; &amp;quot;Min: &amp;quot; &amp;lt;&amp;lt; std::min(a,b) &amp;lt;&amp;lt; std::endl;&lt;br /&gt;
  std::cout &amp;lt;&amp;lt; &amp;quot;Max: &amp;quot; &amp;lt;&amp;lt; std::max(a,b) &amp;lt;&amp;lt; std::endl;&lt;br /&gt;
  }&lt;br /&gt;
  */&lt;br /&gt;
  &lt;br /&gt;
  {&lt;br /&gt;
  double a = 10.3;&lt;br /&gt;
  int b = 5;&lt;br /&gt;
&lt;br /&gt;
  std::cout &amp;lt;&amp;lt; &amp;quot;Min: &amp;quot; &amp;lt;&amp;lt; std::min(a,static_cast&amp;lt;double&amp;gt;(b)) &amp;lt;&amp;lt; std::endl;&lt;br /&gt;
  std::cout &amp;lt;&amp;lt; &amp;quot;Max: &amp;quot; &amp;lt;&amp;lt; std::max(a,static_cast&amp;lt;double&amp;gt;(b)) &amp;lt;&amp;lt; std::endl;&lt;br /&gt;
  }&lt;br /&gt;
  &lt;br /&gt;
  return 0;&lt;br /&gt;
  &lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/source&amp;gt;&lt;/div&gt;</summary>
		<author><name>Daviddoria</name></author>	</entry>

	</feed>