摘要:
001、 [root@PC1 test]# ls a.txt [root@PC1 test]# cat a.txt ## 测试文本 abk akkkkccc 8777 ,,, aaaf 333444 uukk22 [root@PC1 test]# cat a.txt | tr -s [:alnum: 阅读全文
posted @ 2024-09-22 19:52
小鲨鱼2018
阅读(46)
评论(0)
推荐(0)
摘要:
001、 [root@PC1 test]# ls a.txt [root@PC1 test]# cat a.txt ## 测试数据 afdf eDET FDSS FFde fexk mxnd ## 此处应该是个2 [root@PC1 test]# cat a.txt | awk '{for(i = 阅读全文
posted @ 2024-09-22 19:40
小鲨鱼2018
阅读(45)
评论(0)
推荐(0)
摘要:
001、大写转换为小写 [root@PC1 test]# ls a.txt [root@PC1 test]# cat a.txt ## 测试数据 ab cD EF HI KL mn Op qM [root@PC1 test]# sed 's/[A-Z]/\L&/g' a.txt ## 所有的大写转换 阅读全文
posted @ 2024-09-22 19:28
小鲨鱼2018
阅读(163)
评论(0)
推荐(0)
摘要:
001、 >>> list1 ## 测试列表 ['chicken', 'duck', 'goose', 'iron', 'xxx'] >>> list1[:3] ## 前三个 ['chicken', 'duck', 'goose'] >>> list1[-3:] ## 后三个 ['goose', ' 阅读全文
posted @ 2024-09-22 15:11
小鲨鱼2018
阅读(23)
评论(0)
推荐(0)

浙公网安备 33010602011771号