input: Write a function where the task is to produce a given pattern of '#' characters and spaces based on specific conditions. The function should utilize nested loops to iterate through a matrix size of 7x7 and print '#' if the sum of the indices (i + j) is even, otherwise it prints a space. The function should be structured as follows:
  assert create_pattern(7, 7) == None
  assert create_pattern(7, 7) == None
  assert create_pattern(7, 7) == None
  assert create_pattern(7, 7) == None
  assert create_pattern(7, 7) == None
output: def create_pattern(rows, cols):
      for i in range(rows):
          for j in range(cols):
              if (i + j) % 2 == 0:
                  print('#', end='')
              else:
                  print(' ', end='')
          print()