Is there a python function to replace a specific index in a specific list that is in a text file? : <p>What I want to do:
I have a few lists in a text file now and want to change just 1 element of 1 of the lists using python.
What I have done so far:</p>

<p>Current txt file:</p>

<pre><code>food,bought
oranges,yes
strawberry,no
apples,no
</code></pre>

<p>I want it to appear like this after using the code to replace one of the "no" to "yes":</p>

<pre><code>food,bought
oranges,yes
strawberry,no
apples,yes
</code></pre>

<p>Is there any way to specifically change one index of the list?</p>
