Data update
This commit is contained in:
parent
ed705008a8
commit
0df55f9f24
2196 changed files with 32999 additions and 3075 deletions
|
|
@ -62,7 +62,7 @@ extension zhangsuenOp : Matrix<CharValue>
|
|||
{
|
||||
int count := 0;
|
||||
|
||||
for (int i := 0, i < nbrs.Length - 1, i += 1)
|
||||
for (int i := 0; i < nbrs.Length - 1; i += 1)
|
||||
{
|
||||
if (self[r + nbrs[i][1]][c + nbrs[i + 1][0]] == $35)
|
||||
{ count += 1 }
|
||||
|
|
@ -75,7 +75,7 @@ extension zhangsuenOp : Matrix<CharValue>
|
|||
{
|
||||
int count := 0;
|
||||
|
||||
for (int i := 0, i < nbrs.Length - 1, i += 1)
|
||||
for (int i := 0; i < nbrs.Length - 1; i += 1)
|
||||
{
|
||||
if (self[r + nbrs[i][1]][c + nbrs[i][0]] == $32)
|
||||
{
|
||||
|
|
@ -93,9 +93,9 @@ extension zhangsuenOp : Matrix<CharValue>
|
|||
{
|
||||
int count := 0;
|
||||
var group := nbrGroups[step];
|
||||
for(int i := 0, i < 2, i += 1)
|
||||
for(int i := 0; i < 2; i += 1)
|
||||
{
|
||||
for(int j := 0, j < group[i].Length, j += 1)
|
||||
for(int j := 0; j < group[i].Length; j += 1)
|
||||
{
|
||||
var nbr := nbrs[group[i][j]];
|
||||
|
||||
|
|
@ -118,16 +118,16 @@ extension zhangsuenOp : Matrix<CharValue>
|
|||
hasChanged := false;
|
||||
firstStep := firstStep.Inverted;
|
||||
|
||||
for(int r := 1, r < self.Rows - 1, r += 1)
|
||||
for(int r := 1; r < self.Rows - 1; r += 1)
|
||||
{
|
||||
for(int c := 1, c < self.Columns - 1, c += 1)
|
||||
for(int c := 1; c < self.Columns - 1; c += 1)
|
||||
{
|
||||
if(self.proceed(r,c,toWhite,firstStep))
|
||||
{ hasChanged := true }
|
||||
}
|
||||
};
|
||||
|
||||
toWhite.forEach:(p){ self[p.y][p.x] := $32 };
|
||||
toWhite.forEach::(p){ self[p.y][p.x] := $32 };
|
||||
toWhite.clear()
|
||||
}
|
||||
}
|
||||
|
|
@ -136,12 +136,12 @@ extension zhangsuenOp : Matrix<CharValue>
|
|||
{
|
||||
var it := self.enumerator();
|
||||
|
||||
it.forEach:(ch){ console.print(ch," ") };
|
||||
it.forEach::(ch){ console.print(ch," ") };
|
||||
while (it.next())
|
||||
{
|
||||
console.writeLine();
|
||||
|
||||
it.forEach:(ch){ console.print(ch," ") }
|
||||
it.forEach::(ch){ console.print(ch," ") }
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue