I am doing some practice question off a text book and i ran into one thing that i cannot seem to solve
it wants us to remove all files that starts with a number and end is not a letter
so i use Linux and created a few empty file
like this
>1afsd.
>12fdfd
>12dfad
>23fdfa1
>fdafad!
I tried with these
rm -i [0-9] which only remove the ones that have number in it
rm -i *[!a-zA-Z] which only remove the one that does not have a letter in the end
is there a way for it to do both?
i tried
rm -i [0-9]* *[!a-zA-Z] but it just the same command runed twice how do i combine them together ?
Note: I am using the dash -i so I dont delete the file or i have to recreate every time