Ad

Saturday, December 9, 2017

Natural Language Processing with Python

A trick to test input type str.isalpha() str.isalnum()
For example 'a'.isalpha() == True -> True, '5'.isalpha() == True -> False
isalpha() only returns true if the string is completely alphabetical.
numbers need to use isalnum() which refers to is alpha numerical
More string type tricks here https://docs.python.org/3/library/stdtypes.html including how to check for spaces.

No comments:

Post a Comment

React UI, UI UX, Reactstrap React Bootstrap

React UI MATERIAL  Install yarn add @material-ui/icons Reactstrap FORMS. Controlled Forms. Uncontrolled Forms.  Columns, grid