Advertisement
Guest User

Untitled

a guest
Oct 22nd, 2016
123
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C# 3.15 KB | None | 0 0
  1. using System;
  2. using System.Collections.Generic;
  3. using System.Linq;
  4. using System.Text;
  5. using System.Threading.Tasks;
  6.  
  7. namespace AbuzeAccounts
  8. {
  9.     public static class Texts
  10.     {
  11.         public static string[] namesArray = new string[]
  12.         {   "John", "Elthan", "Andrew", "Daniel", "William",
  13.             "Tony", "Hannah", "Wayne", "Alex", "Arnold", "Ashley",
  14.             "Michael", "Joshua", "Emma", "Olivia", "David", "Joseph",
  15.             "Tyler", "Nathan", "Samuel", "Aexis", "Ella", "Julia",
  16.             "Mia", "Noah", "Logan", "Ryan", "Anthony", "David"
  17.         };
  18.  
  19.         private static string[] helloArray = new string[]
  20.         {
  21.             "Hi", "Hello", "Good morning", "Good afternoon",
  22.             "Good evening", "Hi there", "Hello there", "Hey"
  23.         };
  24.  
  25.         private static string[] pointsArray = new string[]
  26.         {
  27.             "!", "."
  28.         };
  29.  
  30.         private static string[] howAreYouArray = new string[]
  31.         {
  32.             "How are you?", "How're you?",
  33.             "How are you doing?", "How're you doing?",
  34.             "What's up?", "How's it going?", "What's new?",
  35.             "What's going on?", "How've you been?",
  36.             "What's happening?", "What're you up to?",
  37.             "Are you staying out of trouble?"
  38.         };
  39.  
  40.         private static string[] emails = new string[]
  41.         {
  42.             @"baylorbelle10@gmail.com",
  43.             @"nicolearreola@gmail.com",
  44.             @"jwtachick@gmail.com",
  45.             @"irehin@aol.com",
  46.             @"gpg863@gmail.com",
  47.             @"dominodave@gmail.com",
  48.             @"mstringf@gmail.com",
  49.             @"nennea@gmail.com",
  50.             @"ez5000k@gmail.com"
  51.         };
  52.  
  53.         public static string GetSendText(int friendsCount, string name)
  54.         {
  55.             string resultText = "";
  56.  
  57.             Random randHelloRand = new Random(),
  58.                 randPointsRand = new Random(),
  59.                 randHowRand = new Random(),
  60.                 existNameRand = new Random(),
  61.                 existHowRand = new Random();
  62.  
  63.             int numHello = randHelloRand.Next(helloArray.Length),
  64.                 numPoint = randPointsRand.Next(pointsArray.Length),
  65.                 numHow = randHowRand.Next(howAreYouArray.Length),
  66.                 existHow = existHowRand.Next(0, 2),
  67.                 existName = existNameRand.Next(0, 2),
  68.                 dollarsCount = 5 * friendsCount;
  69.  
  70.             bool isExistHow = existHow == 1 ? true : false,
  71.                 isExistMyName = existName == 1 ? true : false;
  72.  
  73.             resultText += helloArray[numHello] + pointsArray[numPoint];
  74.             if (isExistMyName) resultText += " My name is " + name + pointsArray[numPoint];
  75.             if (isExistHow) resultText += " " + howAreYouArray[numHow];
  76.             resultText += "\n" + "I've invited " + friendsCount +
  77.                 " friends in a few past months, but after they received orders, I havent received " +
  78.                 dollarsCount + "$ for using my referral code. \nThere are their emails:";
  79.             for (int i = 0; i < friendsCount; i++)
  80.                 resultText += "\n" + emails[i];
  81.  
  82.             return resultText;
  83.         }
  84.     }
  85. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement