Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

visual C# I creating a program that ask the user to enter a name, and it outputs a nickname to the user. everything is working

visual C#

I creating a program that ask the user to enter a name, and it outputs a nickname to the user. everything is working well with the program, I just have one problem. When the user types in their name they are receiving a different nickname everytime. The nickname that is displayed should be the same everytime that the same name is inputed. For example: if the user inputs "Bravo" and his output is "Boy Wonder" then "Boy Wonder is what the output should be everytime that Bravo is entered, and the problem I am having now is that if I were to enter "Bravo" the nickname that is outputted is never the same. attahced is a snap shot of my code I have nowimage text in transcribed

8 public class Program public static void Main() :2 13 5 L6 L7 18 string userInput; Console.WriteLine("Please enter your name to receive a nick name...") string[] firstick new string [30] { "Wild Thing", "Crazy Eyes", "Goofy Goober", "Shady Subject", "Smelly Thing", "Lost One", "Smarty", "Nosey", "Clumsy", "Grumpy", "Happy Feet", "Smiley", "Insane in the membrane", "Sleepy", "BOSS", "Angry One", "Tough One", "Phyco One", "Loving One", "Sneaky", "Caring One", "Crybaby", "Chosen One", "The GOAT", "Annoying One", "Softy", "Scary", "Funky","KooKoo", "Amazing One" Random rannew Random); 23 24 25 Console.Write("insert name: " //create list of objects //input nickname 27 29 userInput-Console.ReadLine); Console.WriteLine("From this point foward you will go by: (0), firstNick[ran.Next (,29)1

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Advanced Database Systems For Integration Of Media And User Environments 98

Authors: Yahiko Kambayashi, Akifumi Makinouchi, Shunsuke Uemura, Katsumi Tanaka, Yoshifumi Masunaga

1st Edition

9810234368, 978-9810234362

More Books

Students also viewed these Databases questions

Question

What qualities do you see as necessary for your line of work?

Answered: 1 week ago