Example #1
0
 function testFnC()
 {
     $this->assertEquals(2, Wumpus::fnC());
     $this->assertEquals(3, Wumpus::fnC());
     $this->assertEquals(1, Wumpus::fnC());
     $this->assertEquals(1, Wumpus::fnC());
     $this->assertEquals(2, Wumpus::fnC());
     $this->assertEquals(4, Wumpus::fnC());
     $this->assertEquals(2, Wumpus::fnC());
     $this->assertEquals(1, Wumpus::fnC());
     $this->assertEquals(3, Wumpus::fnC());
     $this->assertEquals(1, Wumpus::fnC());
 }
Example #2
0
 private static function returnFromGosub()
 {
     if (empty(self::$returnLine)) {
         self::$nextLine = 1151;
     } else {
         self::$nextLine = array_pop(self::$returnLine);
     }
 }
Example #3
0
<?php

require_once 'Wumpus.php';
Wumpus::main();