Hacker News
new
|
past
|
comments
|
ask
|
show
|
jobs
|
submit
login
inp
on Feb 14, 2019
|
parent
|
context
|
favorite
| on:
Problem solving with Unix commands
You can apply the awk command on a pipe, and so it is applies on each line of the file/stream.
darrenf
on Feb 14, 2019
[–]
Right - though that's solvable with xargs:
$ echo "0005" | xargs printf '%d\n' 5
That said, my suggestion doesn't work anyway since the leading 0 marks it as octal, d'oh (as mentioned elsewhere in the thread).
Consider applying for YC's Fall 2025 batch! Applications are open till Aug 4
Guidelines
|
FAQ
|
Lists
|
API
|
Security
|
Legal
|
Apply to YC
|
Contact
Search: