SHARE
TWEET

so cw4

LazySenpai Nov 13th, 2019 (edited) 99 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. if [ $# -ne 1 ]; then
  2.     echo zla liczba parametrow
  3. else
  4.     if [ -f $1 ]; then
  5.         echo "Znaki: `cat $1`"
  6.         ilosc_znakow=`wc $1 -w | cut -f 1 -d" "`
  7.         echo "Ilosc znakow: $ilosc_znakow"
  8.         x=$ilosc_znakow
  9.         while [ $x -ne 0 ] ; do
  10.             znaki_odw="$znaki_odw `cat $1 | cut -f $x -d" "`"
  11.             x=`expr $x - 1`
  12.         done
  13.         echo Wynik dzialania: $znaki_odw
  14.     else
  15.         echo parametr nie jest plikiem
  16.     fi
  17. fi
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
Top