Helpful article!
I prefer the second option as the first option may be confusing later on - why I used that extra nextLine() whereas the second is self-explanatory to me.
This problem also occurs in C++ when using the getline () function to take a string input which you can easily handle by ignoring the \n character seating in the stream due to previous input using cin.ignore() before doing getline.