From 42842a10adcc6f9a7e8f13a97453ddea914e967d Mon Sep 17 00:00:00 2001 From: Akshay Nagpal Date: Wed, 17 May 2017 07:46:18 -0400 Subject: [PATCH] Update README.md --- README.md | 33 ++++++++++++++++----------------- 1 file changed, 16 insertions(+), 17 deletions(-) diff --git a/README.md b/README.md index 1caab23..9bfd2d1 100644 --- a/README.md +++ b/README.md @@ -20,35 +20,34 @@ First you have to import the module using the below code. Then you can use the **word_to_num** method to convert a number-word to numeric digits, as shown below. ``` - print(w2n.word_to_num("two million three thousand nine hundred and eighty four")) - 2003984 +print(w2n.word_to_num("two million three thousand nine hundred and eighty four")) +2003984 ``` ``` - print(w2n.word_to_num('two point three')) - 2.3 +print(w2n.word_to_num('two point three')) +2.3 ``` ``` - print(w2n.word_to_num('112')) - 112 +print(w2n.word_to_num('112')) +112 ``` ``` - print(w2n.word_to_num('point one')) - 0.1 +print(w2n.word_to_num('point one')) +0.1 ``` - ``` - print(w2n.word_to_num('one hundred thirty-five')) - 135 +print(w2n.word_to_num('one hundred thirty-five')) +135 ``` ``` - print(w2n.word_to_num('million million')) - Error: Redundant number! Please enter a valid number word (eg. two million twenty three thousand and forty nine) - None +print(w2n.word_to_num('million million')) +Error: Redundant number! Please enter a valid number word (eg. two million twenty three thousand and forty nine) +None ``` ``` - print(w2n.word_to_num('blah')) - Error: No valid number words found! Please enter a valid number word (eg. two million twenty three thousand and forty nine) - None +print(w2n.word_to_num('blah')) +Error: No valid number words found! Please enter a valid number word (eg. two million twenty three thousand and forty nine) +None ``` ## Bugs/Errors