#!/bin/dash
echo Convert from...
read ext
echo Convert to...
read toext

for i in *.$ext; do ffmpeg -i "$i" "${i%.*}.$toext"; done

while true; do
	read -p "Delete original files? " yn
	case $yn in
		[Yy]* ) rm *.$ext; exit;;
		[Nn]* ) exit;;
		* ) printf "Please answer yes or no. ";;
	esac
done
