9 lines
318 B
Python
9 lines
318 B
Python
import random
|
|
from typing import List
|
|
|
|
def generate_min_path_sum_case(rows: int = 5, cols: int = 5, min_val: int = 1, max_val: int = 20) -> List[List[int]]:
|
|
"""
|
|
Generates a rows x cols grid with random integers.
|
|
"""
|
|
return [[random.randint(min_val, max_val) for _ in range(cols)] for _ in range(rows)]
|