Home PC Games Linux Windows Database Network Programming Server Mobile  
           
  Home \ Programming \ Linux shell scripts bubble sort     - REDO LOG records management (Database)

- Netfilter / Iptables Comments (Linux)

- Oracle 11g partition maintenance (Nice) - Truncating And Partitions (Database)

- grep command output highlighted word (Linux)

- Oracle study notes view (Database)

- Qt signals and slots mechanism (Programming)

- Linux Regular expressions grep and egrep (Linux)

- MySQL backup tool to back up mydumper (Database)

- Cache implementation APP interacts with the server-side interface control Session (Server)

- Linux process scheduling opportunity (Programming)

- 3 ways to create a lightweight, durable system of Ubuntu Linux USB disk (Linux)

- Linux for enterprises to build a firewall (Linux)

- CentOS 6.5 upgrade to CentOS 7 (Linux)

- IOwait Linux system monitoring diagnostic tools (Linux)

- Java garbage collection and heap memory layout (Programming)

- Python in os.path Magical (Programming)

- How to install Unbound and DNSCrypt in Archlinux (Server)

- RedHat Linux 5.5 installation process SVN Service Notes (Server)

- CentOS 7 repair MBR and GRUB (Linux)

- Linux gprof oprofiling and performance testing tools (Linux)

 
         
  Linux shell scripts bubble sort
     
  Add Date : 2017-04-13      
         
         
         
  Manually enter his string, and sorts.
Script as follows:

#! / Bin / bash
#a test about sort
echo "please input a number list"
read -a arrs
for ((i = 0; i < $ {# arrs [@]}; i ++)) {
    for ((j = 0; j < $ {# arrs [@]} - 1; j ++)) {
      if [[$ {arrs [j]} -gt $ {arrs [j + 1]}]]; then
           tmp = $ {arrs [j]}
           arrs [j] = $ {arrs [j + 1]}
           arrs [j + 1] = $ tmp
       fi
}
}
echo "after sort"
echo $ {arrs [@]}
     
         
         
         
  More:      
 
- Object-oriented language Java some of the basic features (Programming)
- BackTrack (BT3, BT4) Linux installation tutorial (Linux)
- The most concise Systemd tutorial, just ten minutes (Linux)
- CentOS / Linux install VNC Server (Linux)
- Effect MongoDB plan cache (Database)
- gzip, bzip2, xz, tar, zip compression, archive Detailed (Linux)
- Using Vagrant to build multi-platform environment (Server)
- Linux tar compressed exclude a folder (Linux)
- Swift defined type conversion and type aliases (typealias) (Programming)
- Linux delete duplicate files Artifact: dupeGuru (Linux)
- Linux Command - ps: a snapshot of the current process (Linux)
- UNIX file permissions in the "set user ID bit" (Linux)
- Java implementation linear table - represents the order of representation and chain (Programming)
- Ubuntu 14.04 / 13.10 users how to install Ubuntu Touch core applications (Linux)
- Linux nice program origin of the name (Linux)
- iOS developers - a simple factory pattern and OC reflection (Programming)
- CentOS 6.5 install Firefox (Linux)
- CentOS 7 install Hadoop-cdh-2.6 (Server)
- Ubuntu Linux use ufw or iptables firewall configuration (Linux)
- Java exception handling mechanism (Programming)
     
           
     
  CopyRight 2002-2020 newfreesoft.com, All Rights Reserved.