title: Is there a better way to write a Regex to match the case,
body: <p>I'm trying to build a Regex which will discard the string if matched.</p>
  
  <p>Case study: Discard the string if it starts with a literal square brackets <code>[]</code></p>
  
  <p>I've tried reading multiple articles on the web for solving the problem, and made a Regex that actually works for me</p>
  
  <p>I've the following paragraph:</p>
  
  <pre><code>[Hello] How are you
  Doing
   Hope you have a nice day!
  [goodbye] cya 
  Take care
  </code></pre>
  
  <p>The regex I'm using is <code>/^(?!\[.?\])/</code></p>
  
  <p>The result is as expected, I wanna know is there a better way to match it ?
  <a href="https://i.stack.imgur.com/tzNqK.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/tzNqK.png" alt="enter image description here"></a></p>