|
|
@@ -725,17 +725,17 @@ class QuestionLocalService
|
|
|
private function calculateDifficultyDistribution(int $category, int $totalQuestions): array
|
|
|
{
|
|
|
// 标准化:25% 低级,50% 基准,25% 拔高
|
|
|
- $lowPercentage = 25;
|
|
|
- $mediumPercentage = 50;
|
|
|
- $highPercentage = 25;
|
|
|
+// $lowPercentage = 25;
|
|
|
+// $mediumPercentage = 50;
|
|
|
+// $highPercentage = 25;
|
|
|
|
|
|
// 根据难度类别调整分布
|
|
|
switch ($category) {
|
|
|
case 1:
|
|
|
// 基础型:0-0.25占50%,其他占50%
|
|
|
- $mediumPercentage = 50; // 0-0.25作为基准
|
|
|
- $lowPercentage = 25; // 其他低难度
|
|
|
- $highPercentage = 25; // 其他高难度
|
|
|
+ $mediumPercentage = 90; // 0-0.25作为基准
|
|
|
+ $lowPercentage = 0; // 其他低难度
|
|
|
+ $highPercentage = 10; // 其他高难度
|
|
|
break;
|
|
|
|
|
|
case 2:
|
|
|
@@ -758,6 +758,10 @@ class QuestionLocalService
|
|
|
$lowPercentage = 25; // 其他低难度
|
|
|
$highPercentage = 25; // 其他高难度
|
|
|
break;
|
|
|
+ default:
|
|
|
+ $lowPercentage = 25;
|
|
|
+ $mediumPercentage = 50;
|
|
|
+ $highPercentage = 25;
|
|
|
}
|
|
|
|
|
|
// 计算题目数量
|