コード例 #1
0
ファイル: oops_comm.php プロジェクト: javiercaceres77/rooms
 private function get_time_from_seconds($seconds)
 {
     $mins = floor($seconds / 60);
     $rest_sec = $seconds - $mins * 60;
     $hours = floor($mins / 60);
     $rest_mins = $mins - $hours * 60;
     $hours = $hours ? add_zeroes($hours) : '00';
     $rest_mins = $rest_mins ? add_zeroes($rest_mins) : '00';
     $rest_sec = $rest_sec ? add_zeroes($rest_sec) : '00';
     return $hours . ':' . $rest_mins . ':' . $rest_sec;
 }
コード例 #2
0
ファイル: rada_crack3.php プロジェクト: Harvie/Programs
        }
    }
    echo "Total not found: {$notfound}\n";
    //Debug
    if ($try > 0) {
        if ($notfound <= $minnotfound || !isset($minnotfound)) {
            echo "-minnf: {$notfound}\n";
            //Debug
            $minnotfound = $notfound;
            $try = $tryes;
        } else {
            $try--;
        }
    } else {
        if ($notfound <= $minnotfound || $notfound == 0) {
            $next = false;
        }
    }
}
//MAIN LOOP
for ($i = $start; $i <= $stop; $i++) {
    //Pridame vsechna zbyla n-cisli
    $istr = add_zeroes($i, $places);
    rada_add("rada", $istr);
}
/////////OUTPUT///////////////////////////////////
echo "\n";
echo "Length: " . strlen($rada) . " chars\n";
echo "Total not found: {$notfound}\n";
echo $rada;
echo "\n\n";