Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- using System;
- using System.Collections.Generic;
- using System.Linq;
- using System.Text;
- using System.Threading.Tasks;
- namespace ConsoleApplication41
- {
- class Program
- {
- static void Main(string[] args)
- {
- int product = 1;
- Random a = new Random();
- while(product<1000)
- {
- int nr = a.Next(1, 10);
- Console.WriteLine(nr);
- product = product * nr;
- }
- Console.WriteLine("the product of the numbers is {0}", product);
- Console.ReadLine();
- }
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement