annotate src/test/csharp/jp.ac.u-ryukyu.ie.cr/data/list/replaceTest.cs @ 7:02b2ab7bffe6

fix
author Kazuma
date Tue, 27 Sep 2016 18:36:05 +0900
parents
children
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
7
Kazuma
parents:
diff changeset
1 using UnityEngine;
Kazuma
parents:
diff changeset
2
Kazuma
parents:
diff changeset
3 public class replaceTest : MonoBehaviour {
Kazuma
parents:
diff changeset
4
Kazuma
parents:
diff changeset
5 // Use this for initialization
Kazuma
parents:
diff changeset
6 void Start () {
Kazuma
parents:
diff changeset
7 List<int> list = new List<int> ();
Kazuma
parents:
diff changeset
8 for (int count = 0; count < 10; count++) {
Kazuma
parents:
diff changeset
9 list = list.addLast (count);
Kazuma
parents:
diff changeset
10 Debug.Log("list" + list.tail());
Kazuma
parents:
diff changeset
11 }
Kazuma
parents:
diff changeset
12 List<int> newList = list.replace (5, 15);
Kazuma
parents:
diff changeset
13 int attribute = list.index (5);
Kazuma
parents:
diff changeset
14 Debug.Log (attribute);
Kazuma
parents:
diff changeset
15 attribute = newList.index (5);
Kazuma
parents:
diff changeset
16 Debug.Log (attribute);
Kazuma
parents:
diff changeset
17 }
Kazuma
parents:
diff changeset
18 }