I need to write a macro that can associate one string with another so I can pass the macro an index string and the macro will then return it's association. The number of associations are in the order of 1000 and are written from a shell script so I can easily include any TeX or LaTeX code and input it in my document.
As an example I would write
Code: Select all
\mymacro{str1}
The input string contains both numbers and underscores so something like
Code: Select all
\newcommand{\str1}{res1}
Any help or guidance is highly appreciated!