Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- using System;
- using System.Globalization;
- using System.Linq;
- namespace ExamPreparation
- {
- public sealed class Startup
- {
- public static void Main()
- {
- string[] phrases = new string[]
- {
- "Excellent product.", "Such a great product.", "I always use that product.",
- "Best product of its category.", "Exceptional product.", "I can’t live without this product."
- };
- string[] events = new string[]
- {
- "Now I feel good.", "I have succeeded with this product.",
- "Makes miracles. I am happy of theresults!", "I cannot believe but now I feel awesome.",
- "Try it yourself, I am very satisfied.", "I feel great!"
- };
- string[] authors = new string[]
- {
- "Diana", "Petya", "Stella", "Elena", "Katya", "Iva", "Annie", "Eva"
- };
- string[] cities = new string[]
- {
- "Burgas", "Sofia", "Plovdiv", "Varna", "Ruse"
- };
- int n = int.Parse(Console.ReadLine());
- Random rnd = new Random();
- for (int i = 0; i < n; i++)
- {
- int randomPhrase = rnd.Next(0, phrases.Length);
- int randomEvent = rnd.Next(0, events.Length);
- int randomAuthor = rnd.Next(0, authors.Length);
- int randomCity = rnd.Next(0, cities.Length);
- string message = phrases[randomPhrase] + " " + events[randomEvent] + " " +
- authors[randomAuthor] + " - " + cities[randomCity];
- Console.WriteLine(message);
- }
- }
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement