Can I use awk to convert all the lower-case letters into upper-case?

后端 未结 6 1248
醉话见心
醉话见心 2020-12-29 01:38

I have a file mixed with lower-case letters and upper-case letters, can I use awk to convert all the letters in that file into upper-case?

6条回答
  •  北海茫月
    2020-12-29 01:52

    You can use awk, but tr is the better tool:

    tr a-z A-Z < input
    

    or

    tr [:lower:] [:upper:] < input
    

提交回复
热议问题