Rang dans une liste
This commit is contained in:
parent
7206afad41
commit
bbff25e369
|
@ -89,6 +89,15 @@ $ kill -9 %% #fg :x
|
||||||
$ exit
|
$ exit
|
||||||
~~~
|
~~~
|
||||||
|
|
||||||
|
## Connaître le rang d'un élément dans une liste
|
||||||
|
|
||||||
|
Utilisation de **tac** pour inverser la liste, sans la trier :
|
||||||
|
|
||||||
|
~~~{.bash}
|
||||||
|
$ ./liste_serveur.sh | tac | grep -n NOUVEAU_SERVEUR
|
||||||
|
2:NOUVEAU_SERVEUR
|
||||||
|
~~~
|
||||||
|
|
||||||
# Fichiers et FS
|
# Fichiers et FS
|
||||||
|
|
||||||
## Ordinaire
|
## Ordinaire
|
||||||
|
|
Loading…
Reference in a new issue