假设我有一份在不同组织部门工作的员工名单。喜欢... Plan => Department => Section或Unit => Department => Section或Department => Section。我需要根据组织部门对它们进行分组。 有时数据会像......
private void CopyWithOffset(char[][] buffer, (int row, int col) offset)
{
if (buffer == null) throw new ArgumentNullException(nameof(buffer));
for (var row = 0; row < buffer.Length; row++)
{
for (var col = 0; col < buffer[row].Length ; col++)
{
int i = row + offset.row;
if (i < _buffer.Length)
{
int j = col + offset.col;
if (j < _buffer[i].Length)
{
_buffer[i][j] = buffer[row][col];
}
}
}
}
}
或者
**Unit Department Section Employee**
Unit-1 Depart-1 Section-1 James
Unit-1 Depart-2 Section-3 Rock
Unit-1 Depart-2 Section-4 Ali
或者
**Plan Department Section Employee**
Plan -1 Depart-1 Section-1 James
Plan -1 Depart-2 Section-3 Rock
Plan -2 Depart-2 Section-4 Ali