forked from code-differently/code-differently-24-q4
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: adds quiz for Hummad (code-differently#129)
* Created new branch * Hummad lesson 3 questions * changed my answers to "unanswered" * adding missing comma * Created new branch * Hummad lesson 3 questions * changed my answers to "unanswered" * delete duplicates * deleted duplicate name in yaml * deleted duplicate * fix: syntax error --------- Co-authored-by: htanweer244 <[email protected]>
- Loading branch information
1 parent
ddcf9f2
commit 314cbaa
Showing
3 changed files
with
69 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,62 @@ | ||
import { | ||
AnswerChoice, | ||
MultipleChoiceQuizQuestion, | ||
QuizQuestion, | ||
QuizQuestionProvider, | ||
} from 'codedifferently-instructional'; | ||
|
||
export class HummadTanweerQuiz implements QuizQuestionProvider { | ||
getProviderName(): string { | ||
return 'hummadtanweer'; | ||
} | ||
|
||
makeQuizQuestions(): QuizQuestion[] { | ||
return [ | ||
HummadTanweerQuiz.makeQuestion0(), | ||
HummadTanweerQuiz.makeQuestion1(), | ||
HummadTanweerQuiz.makeQuestion2(), | ||
]; | ||
} | ||
|
||
private static makeQuestion0(): QuizQuestion { | ||
return new MultipleChoiceQuizQuestion( | ||
0, | ||
'Who is attributed with inventing GIT?', | ||
new Map<AnswerChoice, string>([ | ||
[AnswerChoice.A, 'Linus Torvalds'], | ||
[AnswerChoice.B, 'James Gosling'], | ||
[AnswerChoice.C, 'Koska Kawaguchi'], | ||
[AnswerChoice.D, 'Junio C. Hamano'], | ||
]), | ||
AnswerChoice.UNANSWERED, | ||
); // Replace `UNANSWERED` with the correct answer. | ||
} | ||
|
||
private static makeQuestion1(): QuizQuestion { | ||
return new MultipleChoiceQuizQuestion( | ||
1, | ||
'What is the opposite of a GIT clone?', | ||
new Map<AnswerChoice, string>([ | ||
[AnswerChoice.A, 'GIT add'], | ||
[AnswerChoice.B, 'GIT push'], | ||
[AnswerChoice.C, 'GIT upload'], | ||
[AnswerChoice.D, 'GIT status'], | ||
]), | ||
AnswerChoice.UNANSWERED, | ||
); // Replace `UNANSWERED` with the correct answer. | ||
} | ||
|
||
private static makeQuestion2(): QuizQuestion { | ||
return new MultipleChoiceQuizQuestion( | ||
2, | ||
'How do you check the state of your local git repository since your last commit?', | ||
new Map<AnswerChoice, string>([ | ||
[AnswerChoice.A, 'GIT diff'], | ||
[AnswerChoice.B, 'GIT commit'], | ||
[AnswerChoice.C, 'GIT status'], | ||
[AnswerChoice.D, 'GIT check'], | ||
]), | ||
AnswerChoice.UNANSWERED, | ||
); // Replace `UNANSWERED` with the correct answer. | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters