自动生成的2位数带后缀扫米字符php脚本

自动生成的2位数带后缀扫米字符php脚本
把.hk 修改成你想要的后缀

<?php

// 函数用于生成所有可能的组合
function generateCombinations() {
    $combinations = [];

    // 纯英文组合
    $letters = range('a', 'z');
    foreach ($letters as $letter1) {
        foreach ($letters as $letter2) {
            $combinations[] = $letter1 . $letter2 . '.hk';
        }
    }

    // 纯数字组合
    $numbers = range(0, 9);
    foreach ($numbers as $number1) {
        foreach ($numbers as $number2) {
            $combinations[] = $number1 . $number2 . '.hk';
        }
    }

    // 英文数字混合组合
    foreach ($letters as $letter1) {
        foreach ($numbers as $number2) {
            $combinations[] = $letter1 . $number2 . '.hk';
        }
    }
    foreach ($numbers as $number1) {
        foreach ($letters as $letter2) {
            $combinations[] = $number1 . $letter2 . '.hk';
        }
    }

    return array_unique($combinations); // 去除重复的组合
}

// 生成所有组合
$combinations = generateCombinations();

// 将组合写入文件
$file = fopen('combinations.txt', 'w');
foreach ($combinations as $combination) {
    fwrite($file, $combination . PHP_EOL);
}
fclose($file);

echo "所有组合已生成并保存到 combinations.txt 文件中。";

?>

3A字符代码

<?php

// 函数用于生成所有可能的组合
function generateCombinations() {
    $combinations = [];

    // 纯英文组合
    $letters = range('a', 'z');
    foreach ($letters as $letter1) {
        foreach ($letters as $letter2) {
            foreach ($letters as $letter3) {
                $combinations[] = $letter1 . $letter2 . $letter3 . '.cn';
            }
        }
    }

    // 纯数字组合
    $numbers = range(0, 9);
    foreach ($numbers as $number1) {
        foreach ($numbers as $number2) {
            foreach ($numbers as $number3) {
                $combinations[] = $number1 . $number2 . $number3 . '.cn';
            }
        }
    }

    // 英文数字混合组合
    foreach ($letters as $letter1) {
        foreach ($letters as $letter2) {
            foreach ($numbers as $number3) {
                $combinations[] = $letter1 . $letter2 . $number3 . '.cn';
            }
        }
    }
    foreach ($letters as $letter1) {
        foreach ($numbers as $number2) {
            foreach ($letters as $letter3) {
                $combinations[] = $letter1 . $number2 . $letter3 . '.cn';
            }
        }
    }
    foreach ($numbers as $number1) {
        foreach ($letters as $letter2) {
            foreach ($letters as $letter3) {
                $combinations[] = $number1 . $letter2 . $letter3 . '.cn';
            }
        }
    }
    foreach ($numbers as $number1) {
        foreach ($numbers as $number2) {
            foreach ($letters as $letter3) {
                $combinations[] = $number1 . $number2 . $letter3 . '.cn';
            }
        }
    }
    foreach ($numbers as $number1) {
        foreach ($letters as $letter2) {
            foreach ($numbers as $number3) {
                $combinations[] = $number1 . $letter2 . $number3 . '.cn';
            }
        }
    }
    foreach ($letters as $letter1) {
        foreach ($numbers as $number2) {
            foreach ($numbers as $number3) {
                $combinations[] = $letter1 . $number2 . $number3 . '.cn';
            }
        }
    }

    return array_unique($combinations); // 去除重复的组合
}

// 生成所有组合
$combinations = generateCombinations();

// 将组合写入文件
$file = fopen('combinatio6ns.txt', 'w');
foreach ($combinations as $combination) {
    fwrite($file, $combination . PHP_EOL);
}
fclose($file);

echo "所有组合已生成并保存到 combinations.txt 文件中。";

?>
无标签
评论区
头像