Make a file which kepts on every line a letter, a space, and a real number. For example, it may look like this:
e 5.4
f 3.3
c 2.2
f 1.1
c 2.2
Write a script that uses textscan to read from this file. It will print the sum of the numbers in the file. The script should error-check the file open and close, and print error messages as essential.