Skip Navigation Bar
NLM logo

word-at-a-time


Please note: following the release of the new version of PubMed, the results returned by E-utilities queries of PubMed may differ slightly from those returned in the web version of PubMed. A new PubMed API is currently under development: more information will be announced when available.

As new Insider's Guide classes are no longer being offered, this site is not currently being updated. Please refer to NCBI's E-utilities documentation for more up-to-date information.


The word-at-a-time command combines a series of Unix commands to parse a passage of text into individual lines, with each word appearing on its own line. The command also strips out any punctuation, and converts all uppercase text to lowercase. This command can be useful as a starting point for text-mining projects.

Input

A passage of text.

Output

The input text, with each word split onto its own line, all punctuation removed, and all uppercase letters converted to lowercase.

Arguments

The word-at-a-time command accepts no arguments.

Examples

Given the input text

We the People of the United States, in Order to form a more perfect Union, establish Justice, insure domestic Tranquility, provide for the common defence, promote the general Welfare, and secure the Blessings of Liberty to ourselves and our Posterity, do ordain and establish this Constitution for the United States of America

the word-at-a-time command will output:

we
the
people
of
the
united
states
in
order
to
form
[...]

[...]
establish
this
constitution
for
the
united
states
of
america

Last Reviewed: July 30, 2021