shell十进制转十六进制

dec2hex(){
    printf "0x%x" $1
}

a=$(dec2hex 2131165531)
echo $a

 

posted on 2020-10-20 11:11  裸睡的猪  阅读(2357)  评论(0编辑  收藏  举报