真实的国产乱ⅩXXX66竹夫人,五月香六月婷婷激情综合,亚洲日本VA一区二区三区,亚洲精品一区二区三区麻豆

成都創(chuàng)新互聯(lián)網(wǎng)站制作重慶分公司

shell簡(jiǎn)單計(jì)算器-創(chuàng)新互聯(lián)

#!/bin/bash

function tool_menu()
{
   echo "****************************************************"
   echo "*                                                 *"
   echo "*             calculation tools                 *"
   echo "*                                                 *"
   echo "****************************************************"
}
function menu_choice()
{
   echo "A: Add two num."
   echo "B: Minus two num."
   echo "C: Multiply two num."
   echo "D:Divide two num."
   echo "Q: Close this function."
   echo "Please input your chiose:"
}
function add_num()
{
   echo "please inut your first num:"
   read first_num
   echo "please inut your second num:"
   read second_num
   let add=$first_num+$second_num
   echo "$first_num+$second_num=$add"
   return 0
}
function minus_num()
{
   echo "please inut your first num:"
   read first_num
   echo "please inut your second num:"
   read second_num
   let minus=$first_num-$second_num
   echo "$first_num-$second_num=$minus"
   return 0
}
function multiply_num()
{
   echo "please inut your first num:"
   read first_num
   echo "please inut your second num:"
   read second_num
   let multiply=$first_num*$second_num
   echo "$first_num*$second_num=$multiply"
   return 0
}

function divide_num()
{
   echo "please inut your first num:"
   read first_num
   echo "please inut your second num:"
   read second_num
   let divide=$first_num/$second_num
   echo "$first_num/$second_num=$divide"
   return 0
}
function main()
{
   clear
   tool_menu
   while :
   do
       menu_choice
       read menu_choice
       case $menu_choice in
           A|a) add_num ;;
           B|b) minus_num ;;
           C|c) multiply_num ;;
           D|d) divide_num ;;
           Q|q) break;;
           *) echo "Input error,please try agin.";;
       esac
   done
}
main
exit 0

成都創(chuàng)新互聯(lián)主要從事成都做網(wǎng)站、網(wǎng)站設(shè)計(jì)、外貿(mào)營(yíng)銷網(wǎng)站建設(shè)、網(wǎng)頁(yè)設(shè)計(jì)、企業(yè)做網(wǎng)站、公司建網(wǎng)站等業(yè)務(wù)。立足成都服務(wù)福海,十多年網(wǎng)站建設(shè)經(jīng)驗(yàn),價(jià)格優(yōu)惠、服務(wù)專業(yè),歡迎來(lái)電咨詢建站服務(wù):18980820575

 模板
#!/bin/bash

function tool_menu()
{
   echo "****************************************************"
   echo "*                                                 *"
   echo "*             calculation tools                 *"
   echo "*                                                 *"
   echo "****************************************************"
}
function menu_choice()
{
   echo "A: Add two num."
   echo "B: Minus two num."
   echo "C: Multiply two num."
   echo "D:Divide two num."
   echo "Q: Close this function."
   echo "Please input your chiose:"
}
function add_num()
{

   echo "add."
}
function minus_num()
{

   echo "minus."
}
function multiply_num()
{
   echo "multiply."

}

function divide_num()
{

   echo "divide."

}
function main()
{
   clear 模板

   tool_menu
   while :
   do
       menu_choice
       read menu_choice
       case $menu_choice in
           A|a) add_num ;;
           B|b) minus_num ;;
           C|c) multiply_num ;;
           D|d) divide_num ;;
           Q|q) break;;
           *) echo "Input error,please try agin.";;
       esac
   done
}
main
exit 0

另外有需要云服務(wù)器可以了解下創(chuàng)新互聯(lián)scvps.cn,海內(nèi)外云服務(wù)器15元起步,三天無(wú)理由+7*72小時(shí)售后在線,公司持有idc許可證,提供“云服務(wù)器、裸金屬服務(wù)器、高防服務(wù)器、香港服務(wù)器、美國(guó)服務(wù)器、虛擬主機(jī)、免備案服務(wù)器”等云主機(jī)租用服務(wù)以及企業(yè)上云的綜合解決方案,具有“安全穩(wěn)定、簡(jiǎn)單易用、服務(wù)可用性高、性價(jià)比高”等特點(diǎn)與優(yōu)勢(shì),專為企業(yè)上云打造定制,能夠滿足用戶豐富、多元化的應(yīng)用場(chǎng)景需求。


網(wǎng)站標(biāo)題:shell簡(jiǎn)單計(jì)算器-創(chuàng)新互聯(lián)
本文地址:http://weahome.cn/article/dhhcss.html

其他資訊

在線咨詢

微信咨詢

電話咨詢

028-86922220(工作日)

18980820575(7×24)

提交需求

返回頂部