You've got a number of small, but understandable errors.
SelMonth = {"October_2020"};
The curly braces {} around your character string have created a one element list. I don't know if that was on purpose or not. If your actual problem (as opposed to this example that you've provided) involves a multi-element list (e.g. {"October_2020", "November_2020"}) then some of what is to follow would need to be adjusted. Let us know.
Remove the curly braces to get a character string value.
SelMonth = "October_2020";
The next issue is with your next line:
cYear = (Regex Match (char(SelMonth), "\d{4}") );
Regex Match() returns a list which is going to cause you problems in your next step. It's also overly complicated. Instead, the Word() function is your friend: If you learn only one Formula Editor function, Word() is the one.
cYear=Word(2, SelMonth, "_");
show(cYear);
/*:
cYear = "2020";
On to your next line:
nYear = Num ("cYear");
Here you've put your variable name in quotes which makes it a character literal instead of a variable name. Instead, you should have:
nYear = Num (cYear);
However, getting back to the Regex Match() function returning a list, that will cause a problem here. The Num() function won't take a list as an argument.
If you insist on using Regex Match(), you'll need to specify the element of the list you want to work on using square braces [] as an index.
nYear = Num (cYear[1]);
Note: If you take my suggestion to use the Word() function this is unnecessary.
Putting it all together here's what you need:
Names Default To Here( 1 );
SelMonth = "October_2020";
cYear = (Regex Match (char(SelMonth), "\d{4}") );
cYear=Word(2, SelMonth, "_");
//convert character year to number year
nYear = Num (cYear); //Scripting Guide p137
//Subtract 1 and get previous year
pYear = (nYear - 1);
//convert previous year to character
cpYear = Char ( pYear);
-Jeff