python easy understand
\nclass Solution:\n    def minDeletionSize(self, strs: List[str]) -> int:\n        res=0\n        visited=set()\n        for i in range(len(strs[0])):\n        
```\nclass Solution:\n    def minDeletionSize(self, strs: List[str]) -> int:\n        res=0\n        visited=set()\n        for i in range(len(strs[0])):\n            ##if all ordered correctly, then stop\n            if len(visited)==len(strs)-1:\n                break\n            ##record the indices of correctly ordered str for this round\n            cur = set()\n            for j in range(len(strs)-1):\n                if j in visited:\n                    continue\n                ##if this decides the order, then add it to the visited indices, no need to compute next round\n                if strs[j][i]<strs[j+1][i]:\n                    cur.add(j)\n                ##if this gives wrong order, we have to delete this column\n                if strs[j][i]>strs[j+1][i]:\n                    res+=1\n                    break\n            else:\n                visited=visited.union(cur)\n        return res\n```
[]