I have a list say:
[\'batting average\', \'306\', \'ERA\', \'1710\']
How can I convert the intended numbers without touching the strings?>
changed_list = [int(f) if f.isdigit() else f for f in original_list]