Okay, so to start off I am trying to insert a string into code that I made into string.
Here's what I mean:
x="achievement"
data= f"{x}_scores:[{ score: { type: number}},"
Trying to insert x
into the the string using f-string.
But it keeps saying
NameError: name 'score' is not defined
This is a test I'm doing for a bigger project.
Note that the string I'm inserting into is code I turned into string because I need to insert 100+ words into similar strings, and I can't do it by hand. I'm just trying to generate a list and copy and paste the output elsewhere.
I absolutely need to insert it into that format. Can I get some help?