def write(self, address, value, force=False):
size = len(value)<EOL>if issymbolic(address):<EOL><INDENT>solutions = self._try_get_solutions(address, size, '<STR_LIT:w>', force=force)<EOL>for offset in range(size):<EOL><INDENT>for base in solutions:<EOL><INDENT>condition = base == address<EOL>self._symbols.setdefault(base + offset, []).append((condition, value[offset]))<EOL><DEDENT><DEDENT><DEDENT>else:<EOL><INDENT>for offset in range(size):<EOL><INDENT>if issymbolic(value[offset]):<EOL><INDENT>if not self.access_ok(address + offset, '<STR_LIT:w>', force):<EOL><INDENT>raise InvalidMemoryAccess(address + offset, '<STR_LIT:w>')<EOL><DEDENT>self._symbols[address + offset] = [(True, value[offset])]<EOL><DEDENT>else:<EOL><INDENT>if address + offset in self._symbols:<EOL><INDENT>del self._symbols[address + offset]<EOL><DEDENT>super().write(address + offset, [value[offset]], force)<EOL><DEDENT><DEDENT><DEDENT>
Write a value at address.
:param address: The address at which to write
:type address: int or long or Expression
:param value: Bytes to write
:type value: str or list
:param force: Whether to ignore permissions