Ujjwal123 commited on
Commit
e37d623
·
1 Parent(s): dbd9329

Done successfully

Browse files
Files changed (2) hide show
  1. GridFiller.py +10 -1
  2. log_info.txt +0 -0
GridFiller.py CHANGED
@@ -575,6 +575,7 @@ def solve_grid(grid_json_data,
575
 
576
  rows = grid_json_data['size']['rows']
577
  cols = grid_json_data['size']['cols']
 
578
  grid = grid_json_data['grid']
579
 
580
  main_grid = [['.'] * cols for row in range(rows)]
@@ -616,7 +617,15 @@ def solve_grid(grid_json_data,
616
 
617
  grid_json_data['grid'] = [element for row in main_grid for element in row]
618
 
619
- print(grid_json_data['grid'])
 
 
 
 
 
 
 
 
620
 
621
  print("Loading the Answer-Clue Hash Map !!!")
622
  with open(hash_map_path, 'rb') as f:
 
575
 
576
  rows = grid_json_data['size']['rows']
577
  cols = grid_json_data['size']['cols']
578
+ grid_alt = grid_json_data['grid']
579
  grid = grid_json_data['grid']
580
 
581
  main_grid = [['.'] * cols for row in range(rows)]
 
617
 
618
  grid_json_data['grid'] = [element for row in main_grid for element in row]
619
 
620
+ for i in range(0,len(grid_alt)):
621
+ if(grid_alt[i]=='.'):
622
+ if(grid_json_data['grid'][i]!='.'):
623
+ grid_json_data['grid'][i]='.'
624
+ else:
625
+ if(grid_json_data['grid'][i]=='.'):
626
+ grid_json_data['grid'][i] = ' '
627
+
628
+
629
 
630
  print("Loading the Answer-Clue Hash Map !!!")
631
  with open(hash_map_path, 'rb') as f:
log_info.txt CHANGED
The diff for this file is too large to render. See raw diff