![]() |
|
|
google unix.com
|
|||||||
| Forums | Register | Forum Rules | Links | Albums | FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read |
| Shell Programming and Scripting Post questions about KSH, CSH, SH, BASH, PERL, PHP, SED, AWK and OTHER shell scripts and shell scripting languages here. |
More UNIX and Linux Forum Topics You Might Find Helpful
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| Extract numbers below words with awk | cgkmal | Shell Programming and Scripting | 17 | 01-15-2009 05:48 AM |
| print only last two words of a line | pradeepreddy | Shell Programming and Scripting | 5 | 08-22-2008 02:23 AM |
| Query to print numbers in words | vanitham | Web Programming, Web 2.0 and Mashups | 5 | 08-18-2008 10:52 AM |
| How do I print(save) words to postscript? | luked | High Level Programming | 0 | 07-02-2008 10:56 PM |
| how to separate numbers and words from a file using shell scripts | kamakshi s | UNIX for Dummies Questions & Answers | 1 | 06-26-2008 10:02 AM |
|
|
LinkBack | Thread Tools | Search this Thread | Rate Thread | Display Modes |
|
||||
|
Hi,
I have to write a shell script that converts numbers in to words below is what i wrote.My script is not running. ----------------------------------- echo -n "Enter number : " read n len= echo $n | wc -c echo " number in words : " for ( i=1; i<len; i++ ) do num=echo $n | cut -c i case num in 0) echo -n "zero " ;; 1) echo -n "one " ;; 2) echo -n "two " ;; 3) echo -n "three " ;; 4) echo -n "four " ;; 5) echo -n "five " ;; 6) echo -n "six " ;; 7) echo -n "seven " ;; 8) echo -n "eight " ;; 9) echo -n "nine " ;; esac done --------------------------- Some one please correct me Thanks in Advance bab123 |
| Bookmarks |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|