Skip to content

Lesson 03 chore: fixed quizzes module, yaml, and ananatawas quiz #134

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 8 commits into from
Mar 13, 2025
Merged
Show file tree
Hide file tree
Changes from 7 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
5 changes: 5 additions & 0 deletions lesson_03/quiz/quiz.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,11 @@ quiz:
- $2y$10$FquR69q7W4E68TX/SNCB7u8Ri0DOFRDqsUPdGfuyIBjZJRVFkNI.6
- $2y$10$FSWRA7hulVpyVxd8s67Nxuq/1cdmviW24qqoUbqihBf79cR.w9yly
- $2y$10$Qy1IsNsfuJvA384ypL/72uWubUuNbMRp4LD6j/LM0RIH66D/HIjF6
awatanana:
- $2y$10$uFNj.ocmiXzuuNrZUoIL/OPDaNcu/39W9.BsAZ6zuN7QZLjHik8VG
- $2y$10$TSqcVRhLIrH319zzXZJCMO9TY/Oz4IU96ZBEVk36y98DiwDSZun9G
- $2y$10$MbdEN2Vo/.5Mf5Gc7w.MMuqpFNbBfjXAUTf.PnwzWISzDhcq/Z/Sq
- $2y$10$V6g.2vivPqZpqbteSQ9eZea9LIgRmAXcFLHuFMuGZR7rBts8zePVu
evanphilakhong:
- $2y$10$3ERfjtWq6bYipHm0QGOuDe8oeXth3dnmfxT8g5P65sc8m4EivQNY.
- $2y$10$cr3WSpMx9zljgMYCqz4uYOAMT2iOzDaRsnoQi6CfPu/761F.1EpwW
Expand Down
77 changes: 77 additions & 0 deletions lesson_03/quiz/src/quizzes/ananatawa_quiz.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,77 @@
import {
AnswerChoice,
MultipleChoiceQuizQuestion,
QuizQuestion,
QuizQuestionProvider,
} from 'codedifferently-instructional';

export class AnanatawaQuiz implements QuizQuestionProvider {
getProviderName(): string {
return 'awatanana';
}

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

private static makeQuestion0(): QuizQuestion {
return new MultipleChoiceQuizQuestion(
0,
'What is a pull request?',
new Map<AnswerChoice, string>([
[AnswerChoice.A,'When someone asks to add their changes to the main project.'],
[AnswerChoice.B,'A personal copy of someone elses project that you can make changes to.'],
[AnswerChoice.C,'A toolbox where you can write, commit, and push code.'],
[AnswerChoice.D, 'A request to pull the plug on a project.'],
]),
AnswerChoice.UNANSWERED,
); // Replace `UNANSWERED` with the correct answer.
}

private static makeQuestion1(): QuizQuestion {
return new MultipleChoiceQuizQuestion(
1,
'What does the command git status do?',
new Map<AnswerChoice, string>([
[AnswerChoice.A, 'Make a new git repository'],
[AnswerChoice.B, 'Checks the status of your repository'],
[AnswerChoice.C, 'Stage a file for commit'],
[AnswerChoice.D, 'List all branches in the repository'],
]),
AnswerChoice.UNANSWERED,
); // Replace `UNANSWERED` with the correct answer.
}

private static makeQuestion2(): QuizQuestion {
return new MultipleChoiceQuizQuestion(
2,
'What does the command git pull origin do?',
new Map<AnswerChoice, string>([
[AnswerChoice.A, 'Push the latest changes from the remote repo.'],
[AnswerChoice.B, 'Pull the latest changes from the remote repo.'],
[AnswerChoice.C, 'Display the definition for Git.'],
[AnswerChoice.D, 'Stage a file for commit.'],
]),
AnswerChoice.UNANSWERED,
); // Replace `UNANSWERED` with the correct answer.
}

private static makeQuestion3(): QuizQuestion {
return new MultipleChoiceQuizQuestion(
3,
'What was the first homework assignment that Mr. Mays assigned Cohort 25.1?',
new Map<AnswerChoice, string>([
[AnswerChoice.A, 'Make an account on GitHub.com'],
[AnswerChoice.B, 'Convert a Markdown file into HTML.'],
[AnswerChoice.C, 'Create a personal README and submit via GitHub.'],
[AnswerChoice.D,'Create a personal README and push to Github via VS Code.'],
]),
AnswerChoice.UNANSWERED,
); // Replace `UNANSWERED` with the correct answer.
}
}
2 changes: 2 additions & 0 deletions lesson_03/quiz/src/quizzes/quizzes.module.ts
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@ 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 { AnanatawaQuiz } from './ananatawa_quiz.js';

export const Quizzes = Symbol.for('Quizzes');

Expand All @@ -30,6 +31,7 @@ const QUIZ_PROVIDERS = [
KhaylaSaundersQuiz,
DylanLaffertyQuiz,
RasheedMillerQuiz,
AnanatawaQuiz,
ChanelHuttQuiz,
JeremiahWingQuiz,
JasonWatsonQuiz,
Expand Down