leetcode763专题

Hot100-80(Leetcode763划分字母区间)

代码: class Solution {public List<Integer> partitionLabels(String s) {int n = s.length();boolean f[] = new boolean[n+1];Map<Character,Integer> map = new HashMap<>();for(int i=0;i<n;i++){if(!map.contain

LeetCode763. Partition Labels

文章目录 一、题目二、题解 一、题目 You are given a string s. We want to partition the string into as many parts as possible so that each letter appears in at most one part. Note that the partition is done