Use the 'nextLine()' method. Frame the concept in practical terms so you can explain it during interview discussion.
To read a full line of text input from the user, such as a product name in an e-commerce app, you use the 'nextLine()' method of the Scanner class. This method reads the entire line of input, making it suitable for strings with spaces.