This file contains 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
/// <summary> | |
/// summaryタグを使うとメソッドやクラスの説明を表示してくれます。 | |
/// </summary> | |
void SummaryMethod() | |
{ | |
// 何らかの処理 | |
} |
This file contains 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
/// <Summary> | |
/// ドキュメントコメントについて解説するためのクラスです。 | |
/// </Summary> | |
public class DocCommentClass : MonoBehaviour | |
{ | |
/// <Summary> | |
/// フィールドの説明も書けます。 | |
/// </Summary> | |
public int docId; |
This file contains 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
// コメント文を書くときには「//」を使おう。 | |
int comment = 0; // 行の途中からでもコメント文を書けます。 | |
/* | |
複数行に渡ってコメントを書きたいときには | |
スラッシュとアスタリスクを組み合わせます。 | |
*/ | |
// 複数行のコメントを書くときには |
This file contains 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
using System.Collections; | |
using System.Collections.Generic; | |
using UnityEngine; | |
public class HelloWorld : MonoBehaviour | |
{ | |
void Start() | |
{ | |
Debug.Log("Hello World!"); | |
} |
This file contains 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
元の配列 | |
26, 400, 19, 504, 8, 500, 58, 14, 401, 168, 13 | |
処理中の様子 | |
1週目の処理 : 26, 19, 400, 8, 500, 58, 14, 401, 168, 13, 504 | |
2週目の処理 : 19, 26, 8, 400, 58, 14, 401, 168, 13, 500, 504 | |
3週目の処理 : 19, 8, 26, 58, 14, 400, 168, 13, 401, 500, 504 | |
4週目の処理 : 8, 19, 26, 14, 58, 168, 13, 400, 401, 500, 504 | |
5週目の処理 : 8, 19, 14, 26, 58, 13, 168, 400, 401, 500, 504 | |
6週目の処理 : 8, 14, 19, 26, 13, 58, 168, 400, 401, 500, 504 |
This file contains 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
元の配列 | |
26, 400, 19, 504, 8, 500, 58, 14, 401, 168, 13 | |
処理中の様子 | |
1週目の処理 | |
配列の大きさは11、中身は : 26, 19, 400, 8, 500, 58, 14, 401, 168, 13, 504 | |
配列の大きさは11、中身は : 8, 26, 19, 400, 13, 500, 58, 14, 401, 168, 504 | |
2週目の処理 | |
配列の大きさは11、中身は : 8, 19, 26, 13, 400, 58, 14, 401, 168, 500, 504 | |
配列の大きさは11、中身は : 8, 13, 19, 26, 14, 400, 58, 168, 401, 500, 504 |
This file contains 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
元の配列 | |
26, 400, 19, 504, 8, 500, 58, 14, 401, 168, 13 | |
処理中の様子 | |
1週目の処理 | |
配列の大きさは11、中身は : 26, 400, 19, 504, 8, 500, 14, 58, 168, 401, 13 | |
配列の大きさは11、中身は : 26, 19, 400, 8, 504, 14, 500, 58, 168, 13, 401 | |
2週目の処理 | |
配列の大きさは11、中身は : 19, 26, 8, 400, 14, 504, 58, 500, 13, 168, 401 | |
配列の大きさは11、中身は : 19, 8, 26, 14, 400, 58, 504, 13, 500, 168, 401 |
This file contains 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
元の配列 | |
26, 400, 19, 504, 8, 500, 58, 14, 401, 168, 13 | |
処理中の様子 | |
1週目の処理 h : 8 | |
配列の大きさは11、中身は : 26, 168, 13, 504, 8, 500, 58, 14, 401, 400, 19 | |
2週目の処理 h : 6 | |
配列の大きさは11、中身は : 26, 14, 13, 400, 8, 500, 58, 168, 401, 504, 19 | |
3週目の処理 h : 4 | |
配列の大きさは11、中身は : 8, 14, 13, 168, 26, 500, 19, 400, 401, 504, 58 |
This file contains 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
元の配列 | |
26, 400, 19, 504, 8, 500, 58, 14, 401, 168, 13 | |
*** 最終結果 *** | |
配列の大きさは11、中身は : 8, 13, 14, 19, 26, 58, 168, 400, 401, 500, 504 | |
処理回数は 70 回、 交換回数は 31 回でした。 |
This file contains 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
元の配列 | |
26, 400, 19, 504, 8, 500, 58, 14, 401, 168, 13 | |
処理中の様子 | |
ExecuteQuickSortが呼ばれました。中身は : 26, 400, 19, 504, 8, 500, 58, 14, 401, 168, 13 | |
配列の大きさは11、中身は : 13, 14, 19, 8, 504, 500, 58, 400, 401, 168, 26 | |
左側の範囲 13 から 8 まで / 右側の範囲 504 から 26 まで | |
ExecuteQuickSortが呼ばれました。中身は : 13, 14, 19, 8, 504, 500, 58, 400, 401, 168, 26 | |
配列の大きさは11、中身は : 8, 14, 19, 13, 504, 500, 58, 400, 401, 168, 26 |