title: How to fix 'ValueError: list.remove(x): x not in list' error in Python
body: <p>I'm trying to remove the 'Maths, 76' from my list 'Marks' but it keeps throwing up: </p>
  
  <pre class="lang-py prettyprint-override"><code>line 2, in &lt;module&gt;
      Marks.remove("Maths, 76")
  ValueError: list.remove(x): x not in list
  </code></pre>
  
  <p>I have tried changing the code to have Maths as a separate entity but it has not worked.</p>
  
  <pre class="lang-py prettyprint-override"><code>Marks = ['Amy', 'Jones', 'English', 72, 'Maths', 76, 'Computer Science', 96]
  Marks.remove("Maths, 76")
  print(Marks)
  </code></pre>
  
  <p>I believe the output should just be the list without the variable, but it just outputs the full list.</p>