2390. Removing Stars From a String
Removing Stars From a String - LeetCode 문자열 s가 주어지며, 이 문자열에는 별표(*)가 포함되어 있습니다. 한 번의 연산에서 다음을 수행할 수 있습니다: s에서 별표를 선택합니다. 해당 별표의 가장 가까운 왼쪽에 있는 비 별표 문자를 제거하고, 별표 자체도 제거합니다. 모든 별표가 제거된 후의 문자열을 반환하세요. You are given a string s, which contains stars *. In one operation, you can: Choose a star in s. Remove the closest non-star character to its left, as well as remove the star itself. Return the string a..
LeetCode
2023. 11. 16. 00:04