Code Challenges

Get better at coding with practice problems.

Coding Challenges

Select a problem, write code, run test cases, and submit your solution.

Showing 18 of 37 problems

Implement the minRemoveValidParentheses method that removes the minimum invalid parentheses to make the text valid. Solved

Implement the largestRectangleHistogram method that returns the largest rectangle area possible in a histogram. Solved

Implement the dailyTemperaturesWait method that returns how many days must be waited for a warmer temperature. Solved

Implement the nextGreaterElementArray method that returns the next greater value for each array element. Solved

Implement the validParenthesesMixed method that checks whether mixed parentheses are correctly balanced. Solved

Implement the detectCircularRouteSimple method that checks whether the given movement sequence returns to the starting point. Solved

Implement the validateBookingCapacity method that checks whether a booking request fits within the available capacity. Solved

Implement the findWinnerTicTacToeRow method that returns the winner found in any complete row of a tic-tac-toe board. Solved

Implement the simulateSimpleBrowserBack method that simulates browser back navigation and returns the final page. Solved

Implement the checkBalancedScoreBrackets method that checks whether scored bracket text remains balanced. Solved

Implement the validateStackPushPopSequence method that checks whether a pop sequence is valid for the given push sequence. Solved

Implement the canAttendAllMeetings method that checks whether a person can attend all given meetings. Solved

Implement the rateLimiterAllowRequest method that checks whether a request is allowed under a simple rate limit. Solved

Implement the validateIpSegmentSimple method that checks whether a text segment is valid for an IP address part. Solved

Implement the isValidBracketPairString method that checks whether a bracket string has properly matched and ordered brackets. Solved

Implement the isHappyNumber method that checks whether repeatedly summing the squares of digits reaches 1. Solved