In this task, you are given an input list A. You need to find all the elements of the list that are numbers and calculate their sum.
['U', 'i', 'S', '1271', '3839', 'l', 'h', '4727', 'C', '1215', '5405', '6785', '3625', '219', '8287', '3297', 'p', '6777', 'p', 'q']