#!/usr/bin/env bash for f in ex*.c ; do echo "${f/.c/}" done