2946. Matrix Similarity After Cyclic Shifts

php dev.to

2946. Matrix Similarity After Cyclic Shifts Difficulty: Easy Topics: Mid Level, Array, Math, Matrix, Simulation, Weekly Contest 373 You are given an m x n integer matrix mat and an integer k. The matrix rows are 0-indexed. The following process happens k times: Even-indexed rows (0, 2, 4, ...) are cyclically shifted to the left. Odd-indexed rows (1, 3, 5, ...) are cyclically shifted to the right. Return true if the final modified matrix after k steps is identical to the original ma

Read Full Tutorial open_in_new
arrow_back Back to Tutorials