ls ( –sort option)

UNIX Command

$pwd
/home/jeffrin/shelter/symmel
$ls
beautifulwork  bugs-general  debian-howtos  firewall  language	ovlfose
books	       config-files  Docs	    https:    linux	README
$ls --sort=none
Docs   https:	      language	ovlfose       firewall	    README
books  debian-howtos  linux	bugs-general  config-files  beautifulwork
$ls --sort=time
firewall  Docs	  config-files	 beautifulwork	bugs-general  ovlfose
language  https:  debian-howtos  books		linux	      README
$ls --sort=size
beautifulwork  bugs-general  debian-howtos  firewall  language	ovlfose
books	       config-files  Docs	    https:    linux	README
$ls --sort=extension
beautifulwork  bugs-general  debian-howtos  firewall  language	ovlfose
books	       config-files  Docs	    https:    linux	README
$ls --sort=version
Docs	beautifulwork  bugs-general  debian-howtos  https:    linux
README	books	       config-files  firewall	    language  ovlfose
$


UNIX Explanation

--sort=WORD            sort by WORD instead of name: none -U,
                             extension -X, size -S, time -t, version -v


Theory Drop Related

Names of some sorting algorithms :

Bubble sort
Selection sort
Insertion sort
Shell sort
Comb sort
Merge sort
Heapsort
Quicksort
Counting sort
Bucket sort
Radix sort
Distribution sort
Timsort

CONNECTION

name of sorting algorithms which is knowledge related to sorting

Leave a comment

Your email address will not be published. Required fields are marked *