From 68a7853c56151784985ac418c39a7d7f7b5ca580 Mon Sep 17 00:00:00 2001 From: NelltheWiz Date: Wed, 12 Mar 2025 12:36:57 +0000 Subject: [PATCH] feat branch for lesson3 --- lesson_03/quiz/quiz.yaml | 6 +- lesson_03/quiz/src/quizzes/Chanel_Huttquiz.ts | 68 +++++++++++++++++++ lesson_03/quiz/src/quizzes/quizzes.module.ts | 8 ++- 3 files changed, 78 insertions(+), 4 deletions(-) create mode 100644 lesson_03/quiz/src/quizzes/Chanel_Huttquiz.ts diff --git a/lesson_03/quiz/quiz.yaml b/lesson_03/quiz/quiz.yaml index d61da8187..a983f6426 100644 --- a/lesson_03/quiz/quiz.yaml +++ b/lesson_03/quiz/quiz.yaml @@ -46,4 +46,8 @@ quiz: jasonwatson: - $2y$10$AZtPKyQ.6Bzb.jreO/u.2O3C7XfvYAVpjHzLkuhLVdsX74wc4vXwS - $2y$10$QbKtEXqpeItigRLAHsn8Qe/06ZpXhKEP1bGPJSFXymsoFw9.04NHy - - $2y$10$tJLScW1OZpOLpVllM65EI.W1QjkSIIBtz.KG8z/s.07RNb7ZWC0um \ No newline at end of file + - $2y$10$tJLScW1OZpOLpVllM65EI.W1QjkSIIBtz.KG8z/s.07RNb7ZWC0um + chanelhutt: + - $2y$10$7/GS4n5j/5TXQc5zjDzlc.2xBKwRqrsksWzcl7VKRwa.fDxzdficS + - $2y$10$9mfdal67CXoVG2phPKe1s.BpAT6HQeyQIiDtStfFazkPMW2AaW6Zu + - $2y$10$LiCnvad23bwZWZbxXLhs3.r/YdwIX9eAFtjofaW1AH3Htnc9sEU1G diff --git a/lesson_03/quiz/src/quizzes/Chanel_Huttquiz.ts b/lesson_03/quiz/src/quizzes/Chanel_Huttquiz.ts new file mode 100644 index 000000000..49afd890c --- /dev/null +++ b/lesson_03/quiz/src/quizzes/Chanel_Huttquiz.ts @@ -0,0 +1,68 @@ +import { + AnswerChoice, + MultipleChoiceQuizQuestion, + QuizQuestion, + QuizQuestionProvider, +} from 'codedifferently-instructional'; + +export class ChanelHuttQuiz implements QuizQuestionProvider { + getProviderName(): string { + return 'chanelhutt'; + } + + makeQuizQuestions(): QuizQuestion[] { + return [ + ChanelHuttQuiz.makeQuestion0(), + ChanelHuttQuiz.makeQuestion1(), + ChanelHuttQuiz.makeQuestion2(), + ]; + } + + private static makeQuestion0(): QuizQuestion { + return new MultipleChoiceQuizQuestion( + 0, + 'Which one is not a purpose for git commit?', + new Map([ + [AnswerChoice.A, 'To save changes to your local repository'], + [ + AnswerChoice.B, + 'To provide a clear, descriptive message for the changes made', + ], + [AnswerChoice.C, 'To clear the terminal and re-type the command'], + [AnswerChoice.D, 'Keeps track of changes made to your code'], + ]), + AnswerChoice.UNANSWERED, + ); // Replace `UNANSWERED` with the correct answer. + } + + private static makeQuestion1(): QuizQuestion { + return new MultipleChoiceQuizQuestion( + 1, + 'Which answer best fits the command git push?', + new Map([ + [AnswerChoice.A, 'To move the code to the trash'], + [ + AnswerChoice.B, + 'To transfer files from the local repository to remote repository hosting services', + ], + [AnswerChoice.C, 'To add comments to the code'], + [AnswerChoice.D, 'To merge several branches into one branch'], + ]), + AnswerChoice.UNANSWERED, + ); // Replace `UNANSWERED` with the correct answer. + } + + private static makeQuestion2(): QuizQuestion { + return new MultipleChoiceQuizQuestion( + 2, + 'Which command is used to update the yourlocal repository with changes from your remote repository?', + new Map([ + [AnswerChoice.A, 'git fetch upstream'], + [AnswerChoice.B, 'git pull'], + [AnswerChoice.C, 'git commit'], + [AnswerChoice.D, 'git checkout main'], + ]), + 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 4ec59abb8..f768b1cef 100644 --- a/lesson_03/quiz/src/quizzes/quizzes.module.ts +++ b/lesson_03/quiz/src/quizzes/quizzes.module.ts @@ -1,16 +1,17 @@ import { Module } from '@nestjs/common'; import { AnotherQuiz } from './another_quiz.js'; import { AnthonyMaysQuiz } from './anthony_mays_quiz.js'; -import { JasonWatsonQuiz } from './jason_watson_quiz.js'; -import { MeikoStephensQuiz } from './meiko_stephens_quiz.js'; +import { ChanelHuttQuiz } from './Chanel_Huttquiz.js'; import { DavidAdenaikeQuiz } from './david_adenaike_quiz.js'; import { EvanPhilakhongQuiz } from './evan_philakhong_quiz.js'; import { EzraQuiz } from './ezra_quiz.js'; +import { JasonWatsonQuiz } from './jason_watson_quiz.js'; import { Jbeyquiz } from './jbeyquiz.js'; +import { JeremiahWingQuiz } from './jeremiah_wing_quiz.js'; import { KhaylaSaundersQuiz } from './khayla_quiz.js'; +import { MeikoStephensQuiz } from './meiko_stephens_quiz.js'; import { MercedesMathewsQuiz } from './mercedes_mathews_quiz.js'; import { RasheedMillerQuiz } from './rasheed_miller_quiz.js'; -import { JeremiahWingQuiz } from './jeremiah_wing_quiz.js'; export const Quizzes = Symbol.for('Quizzes'); @@ -27,6 +28,7 @@ const QUIZ_PROVIDERS = [ EvanPhilakhongQuiz, KhaylaSaundersQuiz, RasheedMillerQuiz, + ChanelHuttQuiz, JeremiahWingQuiz, JasonWatsonQuiz, ];