mardi 7 novembre 2017

Using an arraylist and random method to check user input

I am trying to write a program that takes input from the user using a scanner, but then i need to sometimes randomise the user input and check if its true or false.

the output needs to look something like this

Enter word to be tested: Name

Is anem the same as : Name - False

Enter the word to be tested: Rothschild

Is Rothschild the same as: Rothschild - True

Now I am very new to Java and have no idea how to put it all together. Im trying to use a scanner, arraylist and the random util but am struggling to get the code figured out.

Any advice for clarity on how to write this program is much appreciated.




Aucun commentaire:

Enregistrer un commentaire