Deprecated: Return type of myIterator::current() should either be compatible with Iterator::current(): mixed, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in /in/aWoPk on line 13
Deprecated: Return type of myIterator::next() should either be compatible with Iterator::next(): void, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in /in/aWoPk on line 23
Deprecated: Return type of myIterator::key() should either be compatible with Iterator::key(): mixed, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in /in/aWoPk on line 18
Deprecated: Return type of myIterator::valid() should either be compatible with Iterator::valid(): bool, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in /in/aWoPk on line 28
Deprecated: Return type of myIterator::rewind() should either be compatible with Iterator::rewind(): void, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in /in/aWoPk on line 8
Deprecated: Creation of dynamic property myIterator::$position is deprecated in /in/aWoPk on line 5
string(18) "myIterator::rewind"
string(17) "myIterator::valid"
string(17) "myIterator::valid"
string(19) "myIterator::current"
string(15) "myIterator::key"
string(16) "myIterator::next"
string(17) "myIterator::valid"
string(19) "myIterator::current"
string(15) "myIterator::key"
1st iteration
Valid
Current key: 0
Current value: 0
string(16) "myIterator::next"
string(17) "myIterator::valid"
string(19) "myIterator::current"
string(15) "myIterator::key"
2nd iteration
Valid
Current key: 1
Current value: 1
string(16) "myIterator::next"
3rd iteration
Valid
Current key: 2
Current value: 2
4th iteration
Not valid
Current key: NULL
Current value: NULL
5th iteration
Not valid
Current key: NULL
Current value: NULL
Output for 8.3.5
Warning: PHP Startup: Unable to load dynamic library 'sodium.so' (tried: /usr/lib/php/8.3.5/modules/sodium.so (libsodium.so.23: cannot open shared object file: No such file or directory), /usr/lib/php/8.3.5/modules/sodium.so.so (/usr/lib/php/8.3.5/modules/sodium.so.so: cannot open shared object file: No such file or directory)) in Unknown on line 0
Deprecated: Return type of myIterator::current() should either be compatible with Iterator::current(): mixed, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in /in/aWoPk on line 13
Deprecated: Return type of myIterator::next() should either be compatible with Iterator::next(): void, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in /in/aWoPk on line 23
Deprecated: Return type of myIterator::key() should either be compatible with Iterator::key(): mixed, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in /in/aWoPk on line 18
Deprecated: Return type of myIterator::valid() should either be compatible with Iterator::valid(): bool, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in /in/aWoPk on line 28
Deprecated: Return type of myIterator::rewind() should either be compatible with Iterator::rewind(): void, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in /in/aWoPk on line 8
Deprecated: Creation of dynamic property myIterator::$position is deprecated in /in/aWoPk on line 5
string(18) "myIterator::rewind"
string(17) "myIterator::valid"
string(17) "myIterator::valid"
string(19) "myIterator::current"
string(15) "myIterator::key"
string(16) "myIterator::next"
string(17) "myIterator::valid"
string(19) "myIterator::current"
string(15) "myIterator::key"
1st iteration
Valid
Current key: 0
Current value: 0
string(16) "myIterator::next"
string(17) "myIterator::valid"
string(19) "myIterator::current"
string(15) "myIterator::key"
2nd iteration
Valid
Current key: 1
Current value: 1
string(16) "myIterator::next"
3rd iteration
Valid
Current key: 2
Current value: 2
4th iteration
Not valid
Current key: NULL
Current value: NULL
5th iteration
Not valid
Current key: NULL
Current value: NULL
Output for 8.1.0 - 8.1.28
Deprecated: Return type of myIterator::current() should either be compatible with Iterator::current(): mixed, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in /in/aWoPk on line 13
Deprecated: Return type of myIterator::next() should either be compatible with Iterator::next(): void, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in /in/aWoPk on line 23
Deprecated: Return type of myIterator::key() should either be compatible with Iterator::key(): mixed, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in /in/aWoPk on line 18
Deprecated: Return type of myIterator::valid() should either be compatible with Iterator::valid(): bool, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in /in/aWoPk on line 28
Deprecated: Return type of myIterator::rewind() should either be compatible with Iterator::rewind(): void, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in /in/aWoPk on line 8
string(18) "myIterator::rewind"
string(17) "myIterator::valid"
string(17) "myIterator::valid"
string(19) "myIterator::current"
string(15) "myIterator::key"
string(16) "myIterator::next"
string(17) "myIterator::valid"
string(19) "myIterator::current"
string(15) "myIterator::key"
1st iteration
Valid
Current key: 0
Current value: 0
string(16) "myIterator::next"
string(17) "myIterator::valid"
string(19) "myIterator::current"
string(15) "myIterator::key"
2nd iteration
Valid
Current key: 1
Current value: 1
string(16) "myIterator::next"
3rd iteration
Valid
Current key: 2
Current value: 2
4th iteration
Not valid
Current key: NULL
Current value: NULL
5th iteration
Not valid
Current key: NULL
Current value: NULL