Code covered by the BSD License  

Highlights from
Grammatical List

Be the first to rate this file! 4 Downloads (last 30 days) File Size: 1.33 KB File ID: #42311
image thumbnail

Grammatical List

by

 

Takes a cell array of strings and returns a single string with commas and "and" per standard grammar

| Watch this File

File Information
Description

Takes a cell array of strings, i.e. {'one' 'too' 'three' 'for'} and returns a single, grammatically-correct string of the list, i.e. 'one, too, three and for'. Returns 1x1 cells verbatim.

Required Products MATLAB
MATLAB release MATLAB 7.14 (R2012a)
Tags for This File   Please login to tag files.
Please login to add a comment or rating.
Comments and Ratings (1)
22 Jun 2013 Jos (10584)

No oxford comma, you mean. You should make this an option (and default to WITH oxford comma).

And is your example intended to have misspelled numbers? It suggest you're file is not to be taken too seriously.

Contact us