Hi All,
Can anyone help me please,
I have a word like below.
6,76
I want to read this word and check if it has "," (comma) and if yes then i want to replace it with "." (dot). That means i want to be changed to 6.76
If the word doesnot contain "," then its should not be changed.
Eg.
6.74 ----> should be 6.74 only [ i mean no change required]
5,73 ----> should be 5.73 [change required has mentioned above]
777,9 ----> should be 777.9 [change required has mentioned above]
2000 -----> should be 2000 only [ i mean no change required]
those are shell's string operations.
%% deletes the longest part whenever pattern matches at the end.
# deletes the shortest part whenever pattern matched at the beginning.
this is just a short explanation.
agree with that you need to look at the man pages for details.