|The following slightly modified script parses user's input setting word1 as the first word entered and the remainder after first space as word2. FOR /F is the NT batch statement aimed to parse commands output and variables content. Its syntax is quite complex and beyond a short note or quick sample. To get a quick while not friendly help at prompt type for /?|
set /P input=Enter TWO words^>
for /F "tokens=1*" %%a in ("%input%") do if "%%b"=="" (
) else (
echo. the user entered just ONE or NO word.
echo. The user entered "%word1%" and "%word2%"