ASP.NET VB - some mathematics with .NET
4 answers
Very simple, the trick is the ceiling feature provided by most programs. For example, in C # it is a static method inside the Math namespace;
namespace ConsoleDebugger {cool program {static void Main (string [] args) {int lowerLimit = 3; int upperLimit = 10;
int index = 0;
for (int i = lowerLimit; i < upperLimit; i++)
{
for (int j = 0; j < 10; j++)
{
string value = i + "." + j;
Console.WriteLine( value + " " + Round(double.Parse(value)));
}
if (index == 10)
index = 0;
}
Console.ReadLine();
}
private static double Round(double number)
{
return Math.Ceiling(number);
}
}
}
0
source to share