Quantitative assessment of textual complexity