LINUX.ORG.RU

История изменений

Исправление ziemin, (текущая версия) :

echo "aasffdjhdghneeraasdaeaashndasghs" | sed "s/./&\n/g" | (
  while read c
  do
    if [ "${in[x$c]}" != "1" ]
    then
      in[x$c]=1
      echo -n $c
    fi
  done
)

Результат: asfdjhgner

Исправление ziemin, :

echo -n "aasffdjhdghneeraasdaeaashndasghs" | sed "s/./&\n/g" | (
  while read c
  do
    if [ "${in[$c]}" != "1" ]
    then
      in[$c]=1
      echo -n $c
    fi
  done
)

Результат: asfdjhgner

Исходная версия ziemin, :

echo -n "aasffdjhdghneeraasdaeaashndasghs" | sed "s/./&\n/g" | (
  while read c
  do
    if [ "${in[$c]}" != "1" ]
    then
      in[$c]=1
      echo -n $c
    fi
  done
)