Sub Monte_Carlo_Integration_Of_A_Function()
Dim x As Double, y As Double, num As Integer
Randomize()
Console.WriteLine()
Console.WriteLine("Monte Carlo Integration")
Console.WriteLine("XXXXXXXXXXXXXXXXXXXXXXX")
Console.WriteLine("Please Enter A Number?")
num = Console.ReadLine()
x = Rnd()
y = Rnd()
For i = 1 To num
Console.WriteLine(x)
Console.WriteLine(y)
Console.WriteLine()
Next
How do I modify this code to gain distinct, random numbers
Aucun commentaire:
Enregistrer un commentaire