diff --git a/lesson_03/quiz/quiz.yaml b/lesson_03/quiz/quiz.yaml index 91c528293..f81eea68e 100644 --- a/lesson_03/quiz/quiz.yaml +++ b/lesson_03/quiz/quiz.yaml @@ -43,6 +43,10 @@ quiz: - $2y$10$FMRsdjEhIG0anbZOIcVvSOy4e4eFTZGIYYyATChwc.QRMpWuomR5C - $2y$10$0AQW/94c4pPxp8xIhJUIs.qoLnUuQg/Hwe1vd4975K96EKGEPz.H6 - $2y$10$ibNpd6ZjWh/yRXafaN8R5.vxbBw7KVZ7r4IsFv4Uy3naXqagr2B5W + evanderblue: + - $2y$10$jrzJya6WaaYok/vLLHxkSuZR/DxlaKZwFfbLZ0ecoVLL2Xh6yjyDq + - $2y$10$Z1ZuoK050bRTVDb3X/xkcuw1pGQvKGkhoLVqmVABTTOwcJPjsIOG6 + - $2y$10$t3aHn3NxL/fP0n8w2yHm4OnLNF2ZYEztm.Avwgo2vleOkfRWKdRSa lindaquinoa: - $2y$10$c.9r1fNSkCuBu6TBI53vfet82OkufPL4mkFZsocIFpz3dQQoYkL9K - $2y$10$5.x9AKn2gEhew5ek1Y7GguN/bvae2EktevTDpCBvuEjqqOy/MeuHK diff --git a/lesson_03/quiz/src/quizzes/evander_blue_quiz.ts b/lesson_03/quiz/src/quizzes/evander_blue_quiz.ts new file mode 100644 index 000000000..0d194e252 --- /dev/null +++ b/lesson_03/quiz/src/quizzes/evander_blue_quiz.ts @@ -0,0 +1,65 @@ +import { + AnswerChoice, + MultipleChoiceQuizQuestion, + QuizQuestion, + QuizQuestionProvider, +} from 'codedifferently-instructional'; + +export class EvanderBlueQuiz implements QuizQuestionProvider { + getProviderName(): string { + return 'evanderblue'; + } + + makeQuizQuestions(): QuizQuestion[] { + return [ + EvanderBlueQuiz.makeQuestion0(), + EvanderBlueQuiz.makeQuestion1(), + EvanderBlueQuiz.makeQuestion2(), + ]; + } + + private static makeQuestion0(): QuizQuestion { + return new MultipleChoiceQuizQuestion( + 0, + 'What is does the command git push do?', + new Map([ + [AnswerChoice.A, 'Uploads your local commits to a remote repository'], + [ + AnswerChoice.B, + 'Downloads commits from a remote repository to your local machine', + ], + [AnswerChoice.C, 'Creates a new branch in your local repository'], + [ + AnswerChoice.D, + 'Saves your changes to the staging area without committing', + ], + ]), + AnswerChoice.UNANSWERED, + ); // Replace `UNANSWERED` with the correct answer. + } + + private static makeQuestion1(): QuizQuestion { + return new QuizQuestion( + 1, + 'What does RAM stand for?', + 'Random Access Memory', + ); // Provide an answer. + } + + private static makeQuestion2(): QuizQuestion { + return new MultipleChoiceQuizQuestion( + 2, + 'What does a CPU do?', + new Map([ + [AnswerChoice.A, 'Stores long-term data like documents and photos'], + [AnswerChoice.B, 'Controls the display output to the monitor'], + [ + AnswerChoice.C, + 'Executes instructions and performs calculations for the computer', + ], + [AnswerChoice.D, "Provides power to the computer's components"], + ]), + AnswerChoice.UNANSWERED, + ); // Replace `UNANSWERED` with the correct answer. + } +} diff --git a/lesson_03/quiz/src/quizzes/quizzes.module.ts b/lesson_03/quiz/src/quizzes/quizzes.module.ts index fa63181f4..bb07b4830 100644 --- a/lesson_03/quiz/src/quizzes/quizzes.module.ts +++ b/lesson_03/quiz/src/quizzes/quizzes.module.ts @@ -13,6 +13,7 @@ import { TyranRicesQuiz } from './tyran_rices_quiz.js'; import { MarthaOQuiz } from './martha_o_quiz.js'; import { LindaQuinoaQuiz } from './linda_quinoa_quiz.js'; import { DeanWalstonQuiz } from './dean_walston_quiz.js'; +import { EvanderBlueQuiz } from './evander_blue_quiz.js'; export const Quizzes = Symbol.for('Quizzes'); // Add your quiz provider here. @@ -31,6 +32,7 @@ const QUIZ_PROVIDERS = [ DeanWalstonQuiz, KerryFergusonQuiz, MarthaOQuiz, + EvanderBlueQuiz ]; @Module({