Reputation: 87
I have a list of keywords from which I want to create a certain query named _KDWS
. I have a query suffix prefix
and I want to return a string that starts with prefix
and is followed by every keyword from _KWDS
:
something like this:
def _generate_query(self, prefix): # TODO
return f"{prefix} {kwd for kwd in self._KDWS}"
I expect the returned string to look like this:
"prefix kwd1 kwd2 kwd3 kwd4 kwd5 ... kwdN"
Upvotes: 1
Views: 49