Files
School/Anul 1/Semestrul 2/OS/Labs/shell-programming/problem7.sh
T
2024-08-31 12:07:21 +03:00

18 lines
220 B
Bash

#!/bin/bash
check=0
if test -f $1;then
while read -r X;do
if test $check -eq 1;then
printf ","
fi
printf "$X"
printf "@scs.ubbcluj.ro"
check=1
done < "$1"
printf '\n'
else
echo "Not a valid file"
fi