Skip to content

Lesson 03 Quiz w/Merge Conflicts Resolved #106

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 11 commits into from
Oct 1, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions lesson_03/quiz/quiz.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,10 @@ quiz:
anotherone:
- $2y$10$8eHSzy3aCu4Ry3LzO9nWCeGpofSxsNVbnF.wCfn3ZADwQ6MEtN/KK
- $2y$10$dGB0CGv7.XQC5OqfyY6iXOiJsdVyxU3ve5YE0gt4m2I8P8H13lNXa
chigazograham:
- $2y$10$OTnSih9kHykUnsuM/YKufu3MXTpOZrif.dL13XwXt8rquJL4mV.m.
- $2y$10$je60MntrKRBd/1tz7hNUY.D/cyKOEM.hp6/1fVVVGJRIIitmUGI5e
- $2y$10$pPTmEp0acs8.NIAamLpmmuF7B72bXFZsikHywQI/JvfXuySkhHH5S
oyeyemijimoh:
- $2y$10$2LlSxAEM1HmR3Wl2fO6LQueu/77spr5SuWAh4b3MKesIWNy3CFjGe
- $2y$10$csA90DFxK7.uq6dSfS06Yukk5fQPrzLvU2Lp43ArTs2za28LVvRGO
Expand Down
62 changes: 62 additions & 0 deletions lesson_03/quiz/src/quizzes/chigazo_graham_quiz.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,62 @@
import {
AnswerChoice,
MultipleChoiceQuizQuestion,
QuizQuestion,
QuizQuestionProvider,
} from 'codedifferently-instructional';

export class ChigazoGrahamsQuiz implements QuizQuestionProvider {
getProviderName(): string {
return 'chigazograham';
}

makeQuizQuestions(): QuizQuestion[] {
return [
ChigazoGrahamsQuiz.makeQuestion0(),
ChigazoGrahamsQuiz.makeQuestion1(),
ChigazoGrahamsQuiz.makeQuestion2(),
];
}

private static makeQuestion0(): QuizQuestion {
return new MultipleChoiceQuizQuestion(
0,
'What is the sign for modulo?',
new Map<AnswerChoice, string>([
[AnswerChoice.A, '^'],
[AnswerChoice.B, '*'],
[AnswerChoice.C, '%'],
[AnswerChoice.D, '//'],
]),
AnswerChoice.UNANSWERED,
); // Provide an answer. | AnswerChoice.C, '%'
}

private static makeQuestion1(): QuizQuestion {
return new MultipleChoiceQuizQuestion(
1,
'Who are hip hops big three',
new Map<AnswerChoice, string>([
[AnswerChoice.A, 'Kendrick Lamar, J. Cole, and Drake'],
[AnswerChoice.B, 'Tupac, Biggie, and Nas'],
[AnswerChoice.C, 'Kanye West, Eminem, and Lil Wayne'],
[AnswerChoice.D, 'K. Dot'],
]),
AnswerChoice.UNANSWERED,
); // Provide an answer. | AnswerChoice.C, '%'
}

private static makeQuestion2(): QuizQuestion {
return new MultipleChoiceQuizQuestion(
2,
'what is the answer to life, the universe, and everything else?',
new Map<AnswerChoice, string>([
[AnswerChoice.A, '42'],
[AnswerChoice.B, 'Jesus'],
[AnswerChoice.C, 'N/A'],
[AnswerChoice.D, 'Whatever you want it to be!'],
]),
AnswerChoice.UNANSWERED,
); // Provide an answer. | AnswerChoice.A, '42'
}
}
3 changes: 2 additions & 1 deletion lesson_03/quiz/src/quizzes/quizzes.module.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@ import { Module } from '@nestjs/common';
import { AnotherQuiz } from './another_quiz.js';
import { OyeyemiJimohQuiz } from './oyeyemi_jimoh_quiz.js';
import { AnthonyMaysQuiz } from './anthony_mays_quiz.js';
import { ChigazoGrahamsQuiz } from './chigazo_graham_quiz.js';
import { JosephCaballeroQuiz } from './joseph_caballero_quiz.js';
import { YafiahAbdullahQuiz } from './yafiah_abdullah_quiz.js';

Expand All @@ -15,7 +16,7 @@ const QUIZ_PROVIDERS = [
AnotherQuiz,
JosephCaballeroQuiz,
OyeyemiJimohQuiz,
];
ChigazoGrahamsQuiz];

@Module({
providers: [
Expand Down