答案1
通过在序言中添加以下内容“解决”:
\DeclareExerciseEnvironmentTemplate{custom}{%
\GetExerciseHeadingF{\subsection*}%
{\XSIMmixedcase{\GetExerciseName}\nobreakspace
\GetExerciseProperty{counter}
\IfInsideSolutionF{%
\GetExercisePropertyT{points}{\normalfont %
(%
\printgoal{\PropertyValue}
\IfExerciseGoalSingularTF{points}
{\XSIMtranslate{point}}
{\XSIMtranslate{points}}%
)%
}}%
}%
\par}
\DeclareExerciseType{problem}{
exercise-env = problem ,
solution-env = answer ,
exercise-name = Problem ,
solution-name = Answer ,
exercise-template = custom ,
solution-template = custom
}
现在输出结果为: