1820. 最多邀请的个数

匈牙利算法:

class Solution {
    public int maximumInvitations(int[][] grid) {
        int m = grid.length;
        int n = grid[0].length;
  
        int res = 0;
        
        boolean use[] = new boolean[n];
        int[] next = new int[n];
        Arrays.fill(next, -1);
        for(int i=0; i

你可能感兴趣的:(1820. 最多邀请的个数)