#!/bin/bash

if [ "$#" != "1" ]; then
	echo "usage: $0 [filelist.txt]"
	exit 1
fi

FLIST=$1

if ! [ -f $1 ]; then
	echo "$FLIST not found"
	exit 3
fi

cat $FLIST | while read -r fil
do

	if [ -f $fil ]; then
		wc -c $fil
	fi

done
