make sure that input has two decimal place
<pre><code>Console.Write("Input price: ");
double price;
string inputPrice = Console.ReadLine();
if (double.TryParse(inputPrice, out price))
{
    price = double.Parse(inputPrice);
}
else
{
    Console.WriteLine("Inventory code is invalid!");
}
</code></pre>

<p>so i have to make sure that the price that will be inputed has and must be 2 decimal places. Such as the following:</p>

<ul>
<li>2.00  - correct</li>
<li>3.65  - correct</li>
<li>77.54 - correct</li>
<li>34.12 - correct</li>
</ul>

<p>but</p>

<ul>
<li>2     - wrong</li>
<li>2.8   - wrong</li>
<li>2.415 - wrong</li>
<li>99.0 - wrong</li>
</ul>

<p>how should i check for it it?</p>
