Skip to content

11. Container With Most Water - #111

Open
kazuki-official wants to merge 1 commit into
mainfrom
11-container-with-most-water
Open

11. Container With Most Water#111
kazuki-official wants to merge 1 commit into
mainfrom
11-container-with-most-water

Conversation

@kazuki-official

Copy link
Copy Markdown
Owner

Comment thread memo.md
* `[3, 6, 1]`などの場合は, 更新のやり方によっては最大の水を捉えられない.

```cpp
#include <vector>

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

include 文を書く際、ファイル名の辞書順で並べるスタイルもあります。

参考までにスタイルガイドへのリンクを共有いたします。

https://google.github.io/styleguide/cppguide.html#Names_and_Order_of_Includes

Within each section the includes should be ordered alphabetically.

なお、このスタイルガイドは“唯一の正解”というわけではなく、数あるガイドラインの一つに過ぎません。チームによって重視される書き方や慣習も異なります。そのため、ご自身の中に基準を持ちつつも、最終的にはチームの一般的な書き方に合わせることをお勧めします。

Copy link
Copy Markdown
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

知らなかったです。今後の演習で意識するようにします。

Comment thread memo.md
}

private:
void BuildImplementation(int node_i, int left, int right){

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

{ の前にスペースが空いているものと空いていないものが混ざっているのが気になりました。空けるほうに統一することをお勧めいたします。

Comment thread memo.md
BuildImplementation(1, 0, array_.size() - 1);
}

void Update(int array_i, int new_value){

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

array_index とフルスペルで書いたほうが、読み手にとって読みやすくなると思います。

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants