Returning a Random Number Type Problem
<p>I'm trying to return a random number from a method but apparently the implicit type is not correct. It says "Cannot implicitly convert type 'Randomize.RandomNumber' to 'int'"</p>

<p>RandomNumber.cs:</p>

<pre><code>using System;
using System.Collections.Generic;
using System.Text;

namespace Randomizer
{
    class RandomNumber
    {
        public int RandomInRange(int l, int u)
        {
            Random generator = new Random();
            return generator.Next(l, u);
        }

    }
}
</code></pre>

<p>Program.cs:</p>

<pre><code>using System;
using System.Collections.Generic;
using System.Text;

namespace Randomizer
{
    class Program
    {
        static void Main(string[] args)
        {
            Console.Out.WriteLine("Please enter the minimum range for the random number\n");
            int min = int.Parse(Console.In.ReadLine());

            Console.Out.WriteLine("Please enter the maximum range for the random number\n");
            int max = int.Parse(Console.In.ReadLine());

            int RandomInt = new RandomNumber();

            Console.Out.WriteLine("Your random number is: " + RandomInt.RandomInRange(min, max));

            Console.In.ReadLine();
        }
    }

}
</code></pre>

<p>I know it's pretty much a noob question, but I'm used to C++. Thanks for the help in advance. =]</p>
