title: Regex and python to express not matching more than one consecutive characters
body: <p>I know in regex we can use <code>^</code> to declare something except. For example <code>[^ ]*?</code> means a string with no space. How we can use this to find the except for more than two consecutive character. Fro example a string that doesn't contain <code>{{</code> when it can contain a single <code>{</code>. I tried these and didn't work:</p>
  
  <pre><code>re.compile(r"(\{\{`[^(\{\{)]*?\}\}`)
  re.compile(r"(\{\{`[^\{\{]*?\}\}`)
  </code></pre>
  
  <p>This is to catch strings in a file that starts with <code>{{</code> and ends with <code>}}</code> but doesn't contains <code>}}</code> while they can contain a single <code>}</code>. Also using <code>.*</code> is not an option.</p>
  
  <pre><code>input_string="blah blah blah {{cite journal |last=Malatesta|first=Errico|title=Towards Anarchism|journal=MAN!|publisher=International Group of San Francisco|location=Los Angeles|oclc=3930443|url=http://www.marxists.org/archive/malatesta/1930s/xx/toanarchy.htm|archiveurl=http://web.archive.org/web/20121107221404/http://marxists.org/archive/malatesta/1930s/xx/toanarchy.htm|archivedate=7 November 2012 |deadurl=no|authorlink=Errico Malatesta |ref=harv}} blah blah blah"
  regexp_1 = re.compile(r"(\{\{[^\}]*?\}\})") 
  output = regexp_1.sub("",input_string )
  </code></pre>
  
  <p>Now <code>regexp_1</code>, I want to replace <code>[^\}]*?</code> with <code>[^\}\}]*?</code> and I know that <code>[^\}\}]*?</code> is not correct since it works the same way as <code>[^\}]*?</code>.</p>