Home > php教程 > php手册 > body text

PHP自然语言倒序的具体实现方式

WBOY
Release: 2016-06-13 11:06:50
Original
1175 people have browsed it

PHP自然语言倒序示例如下

  1. php 
  2. $data = array("book-1", "book-10", 
    "book-100", "book-5");natsort($data); 
    print_r(array_reverse($data));  
  3. ?> 
Copy after login

下面是它的输出结果:

Array ([0] => book-100

[1] => book-10

[2] => book-5

[3] => book-1

)

希望初学者们通过上面这段例子能够弄清PHP自然语言倒序的具体使用方式。


source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template
About us Disclaimer Sitemap
php.cn:Public welfare online PHP training,Help PHP learners grow quickly!