Use the methods available in GUI or GUILayout to create an input field for the user or read Input.GetKeyDown inside Update to piece a string together when the user hits a key. There’s no concept of reading an input string out of the console in Unity.
You would need to use GUI controls and have a label saying “Enter The Word” then a textfield for the input but use a button to submit the input then call a function or whatever to compare the input string with word1 then display another label based on this comparison.