Automatically manipulate text file

I have large text file with latitude and longitude numbers (example below)

3297180377635758  -1170703125
3297180377635722  -1170703154
3297180377635745  -1170703186

These latitude and longitude numbers are missing the decimal points, it should like this

32.97180377635758  -117.0703125
32.97180377635722  -117.0703154
32.97180377635745  -117.0703186

Using Linux commands like grep, awk, or sed (or something).  How can I automatically add these decminal points?



LVL 1
Knowledge01Asked:
Who is Participating?
 
regelandConnect With a Mentor Commented:
awk '{print substr($1,1,22) "." substr($1,23)}' filename > output
0
 
Knowledge01Author Commented:
Thank you very much, thats perfect.  I played with the numbers and that resolved my problem.
0
All Courses

From novice to tech pro — start learning today.