File tree Expand file tree Collapse file tree 1 file changed +3
-11
lines changed Expand file tree Collapse file tree 1 file changed +3
-11
lines changed Original file line number Diff line number Diff line change @@ -149,18 +149,10 @@ function addCompanyProblems(sortMethod: string) {
149
149
difficulty : correspondingLeetcodeProblem ?. difficulty_lvl , // Add difficulty
150
150
acceptance : correspondingLeetcodeProblem ?. acceptance , // Add acceptance
151
151
} ) ;
152
- } ) ;
153
- }
154
152
155
- // Check if companyProblems is an array before proceeding
156
- if ( Array . isArray ( companyProblems ) ) {
157
- companyProblems . forEach ( ( problem ) => {
158
- solutions . push ( {
159
- id : problem . id ,
160
- title : problem . title ,
161
- url : `https://leetcode.com/problems/${ problem . title . replace ( / \s / g, '-' ) } /` ,
162
- frequency : problem . freq_alltime ,
163
- } ) ;
153
+ // Update min and max frequency
154
+ if ( problem . freq_alltime < minFrequency ) minFrequency = problem . freq_alltime ;
155
+ if ( problem . freq_alltime > maxFrequency ) maxFrequency = problem . freq_alltime ;
164
156
} ) ;
165
157
}
166
158
You can’t perform that action at this time.
0 commit comments