Home
Atelier Chikuma
Cancel

Leetcode 1367 - Linked List in Binary Tree

Link to problem Problem Given a binary tree rootand a linked list with head as the first node. Return True if all the elements in the linked list starting from the head correspond to some downwa...

Leetcode 1451 - Rearrange Words in a Sentence

Link to problem Problem Given a sentence text (A sentence is a string of space-separated words) in the following format: First letter is in upper case. Each word in text are separated by a ...

Leetcode 376 - Wiggle Subsequence

Link to problem Problem A wiggle sequence is a sequence where the differences between successive numbers strictly alternate between positive and negative. The first difference (if one exists) may...

Leetcode 2368 - Reachable Nodes With Restrictions

Link to problem Problem There is an undirected tree with n nodes labeled from 0 to n - 1 and n - 1 edges. You are given a 2D integer array edges of length n - 1 where edges[i] = [ai, bi] indicat...

Leetcode 81 - Search in Rotated Sorted Array II

Link to problem Problem There is an integer array nums sorted in non-decreasing order (not necessarily with distinct values). Before being passed to your function, nums is rotated at an unknown ...

Leetcode 769 - Max Chunks To Make Sorted

Link to problem Problem You are given an integer array arr of length n that represents a permutation of the integers in the range [0, n - 1]. We split arr into some number of chunks (i.e., parti...

Leetcode 2316 - Count Unreachable Pairs of Nodes in an Undirected Graph

Link to problem Problem You are given an integer n. There is an undirected graph with n nodes, numbered from 0 to n - 1. You are given a 2D integer array edges where edges[i] = [ai, bi] denotes t...

Leetcode 347 - Top K Frequent Elements

Link to problem Problem Given an integer array nums and an integer k, return the k most frequent elements. You may return the answer in any order. Solution I have two slightly different solutio...

Leetcode 1895 - Largest Magic Square

Link to problem Problem A k x k magic square is a k x k grid filled with integers such that every row sum, every column sum, and both diagonal sums are all equal. The integers in the magic square...

Third Parties and FFXIV

Recently, a footage showing world first clear of The Omega Protocol using plugins that could zoom in sparked the discussion of the use of third party tools (again). The problem was solved by SE in ...