How would I go about taking a string:
("h1", "h2", "h3, "h4")
And substituting these values with numbers 1, 2, 3, 4?
Correspondingly, how I would I preform the same operation but on a list instead?
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
If this is what you want.
It’s not exactly clear; I’m assuming that your input is not literally a string
"(\"h1\", \"h2\", \"h3\", \"h4\")", but a list of strings.And I’m not sure what you meant by your second question, as it appears to be the same as the first.
I will update my answer accordingly =)