久久久久久久视色,久久电影免费精品,中文亚洲欧美乱码在线观看,在线免费播放AV片

<center id="vfaef"><input id="vfaef"><table id="vfaef"></table></input></center>

    <p id="vfaef"><kbd id="vfaef"></kbd></p>

    
    
    <pre id="vfaef"><u id="vfaef"></u></pre>

      <thead id="vfaef"><input id="vfaef"></input></thead>

    1. 站長(zhǎng)資訊網(wǎng)
      最全最豐富的資訊網(wǎng)站

      php如何在不去重的情況下對(duì)數(shù)組排序

      php在不去重的情況下對(duì)數(shù)組排序的方法:【$cars=array("porsche","BMW","Volvo");sort($cars);】,表示按照字母升序?qū)?shù)組中的元素進(jìn)行排序。

      php如何在不去重的情況下對(duì)數(shù)組排序

      函數(shù)介紹:

      sort() – 以升序?qū)?shù)組排序

      rsort() – 以降序?qū)?shù)組排序

      (推薦教程:php視頻教程)

      舉例:

      按照字母升序?qū)?shù)組 $cars 中的元素進(jìn)行排序

      代碼實(shí)現(xiàn):

      <?php $cars=array("porsche","BMW","Volvo"); sort($cars); ?>

      按照數(shù)字升序?qū)?shù)組 $numbers 中的元素進(jìn)行排序

      代碼實(shí)現(xiàn):

      <?php $numbers=array(3,5,1,22,11); sort($numbers); ?>

      按照字母降序?qū)?shù)組 $cars 中的元素進(jìn)行排序

      <?php $cars=array("porsche","BMW","Volvo"); rsort($cars); ?>

      按照數(shù)字降序?qū)?shù)組 $numbers 中的元素進(jìn)行排序

      <?php $numbers=array(3,5,1,22,11); rsort($numbers); ?>

      贊(0)
      分享到: 更多 (0)
      ?
      網(wǎng)站地圖   滬ICP備18035694號(hào)-2    滬公網(wǎng)安備31011702889846號(hào)