solve: 3.Longest Substring Without Repeating Characters#48
Open
solve: 3.Longest Substring Without Repeating Characters#48
Conversation
oda
reviewed
Feb 18, 2026
| 簡易的なベンチマークとの比較 | ||
| 手元の環境(Apple M4(10 cores))での簡易的なベンチマーク(デバッグビルド)は平均59.874msとなった。 | ||
| 秒あたり10億ステップの概算では230msとなったので、ベンチマーク結果と4倍程度の差となった。 | ||
| 見積もろうとしている計算時間のスケールを考えると、概算にしては良いところまで見積もれているように思った。 |
There was a problem hiding this comment.
一般論として、時間の見積もりは安全側に倒したいので(間に合わないと大きな問題だが、速すぎても大きな問題ではないことが多い)数倍くらい長めにでているくらいがちょうどいいだろうと思います。
あんまりにもぎりぎりそうだったら、「時間を測ってみたい」と感じることも大事です。
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
問題: 3. Longest Substring Without Repeating Characters
次に解く問題: 209. Minimum Size Subarray Sum
ファイルの構成:
./src/bin/<各ステップ>.rs