You can not have commands with numbers in their name
You could have
\newcommand{\C}[1]{\textscn{C#1}}
defining \C to take an argument so \C4 or \C3 would work, as would \C{hello world}
However I would avoid 1-letter commands, most are pre-defined in latex for accents and similar commands. For example if you start using \C you might be tempted to need \c for a lowercase version but \c is the cedilla accent.
I would use a slighly longer name such as
\newcommand{\upC}[1]{\textscn{C#1}}
which would allow \upC4 and \upC5
or a name based on the semantic meaning, whatever that is. For example:
\newcommand{\category}[1]{\textscn{C#1}}
which would allow \category4 and \category5 if C4 stood for "category 4" in your real context.
Civ. Case-sensitive. Be sure tha the desired command is not already used by a package. – rallg Nov 30 '23 at 23:11\newcommand{\C}[1]{\textscn{C#1}}would allow\C4and\C5etc – David Carlisle Nov 30 '23 at 23:52