li>
          <strong>'x'</strong> (Exclusive Creation): Creates a new file but gives an error if the file already exists.
        </li>
      </ul>

      <h3>Example 1: Open a File in Read Mode</h3>
      <p>
        Let’s say we have a file named <code>example.txt</code> that contains some text. We want to open it and read its
        content:
      </p>
      <div class="code-block">
        <pre>
# Example: Open and Read a File
file = open("example.txt", "r")  # Open the file in 'r' (read) mode
conte