Category: c / c++
Given a two-dimensional matrix of integers matrix, determine whether it’s a Toeplitz matrix. A Toeplitz is one where every diagonal descending from left to right has the same value. …
Given a positive integer, output its complement number. The complement strategy is to flip the bits of its binary representation. The given integer is guaranteed to fit within the …
We are to write the letters of a given string S, from left to right into lines. Each line has maximum width 100 units, and if writing a letter …
Given a string, you need to reverse the order of characters in each word within a sentence while still preserving whitespace and initial word order. Input: “Let’s take LeetCode …
Design a logger system that receive stream of messages along with its timestamps, each message should be printed if and only if it is not printed in the last …