Introduction
Design a fun and interactive “This or That?” personality quiz using simple coding! In this creative project, students write three playful questions, create answer buttons, and use number variables to track points for each personality type. At the end, they code a result page using logic blocks to reveal a custom message. This beginner-friendly lesson combines writing, critical thinking, and coding — perfect for middle schoolers learning how to build their own interactive games and quizzes.
Objectives
Students will:
- Plan and define a theme with two personality sides
- Write three creative questions with two personality-based answers
- Use number variables and add points to track each side
- Use a Compare block to code the result page logic
- Test and revise their quiz using peer feedback and checklists
Code Stories and Games with Elementari
Elementari helps students personalize stories and games with simple coding. In this project, students use number variables to track choices and reveal a custom result based on their answers. By combining playful writing with interactive logic, students explore how even basic code can make stories come alive in a new way.
New to Elementari? Click on the orange Start button to jump right into the lesson for free. Check out our Getting Started Guide for an overview of how Elementari works with your class. Get started for free for up to 35 student accounts.
Teacher Notes
The most important part is the pre-writing organizer. Once that is done, students can easily copy and paste their questions / answers and follow Elementari's step-by-step instructions for building their quiz.
Before Coding:- Have students complete the Writing Organizer to plan their theme, sides, variables, and questions.
- Show a sample project so students see how the quiz flow works.
- Model a quick, silly “This or That” quiz live to introduce the concept.
- Have students test their quiz using Inspect Mode and try different answer combinations.
- Use the Single Point Rubric to assess projects.
- Use the
Lesson Resources
Coding Concepts Covered
Functions in Sequence Function in Parallel User Navigation Increment Number Variable ConditionalsStudent Instructions
Use your This That Personality Quiz Writing Organizer (Make a Copy)to help plan:
- What is the theme of your quiz?
- What are the two sides (personalities)?
- What questions will you ask?
View the Example Project
Choose a clear “This or That?” topic (e.g. Sweet vs. Salty). Write your title with a button to start the quiz.
Code Overview: Use the Create Text Variables
block to create and name your two variables (ex. sweet_side and salty_side )
Write a question with two answer buttons. Assign each answer to one of your two personality sides.
Use the Increment Variable
block to add a point to Side A when the matching button is clicked. Then, send the player to the next page.
Copy your code for Side B.
Duplicate the slide for Question 2 — it copies all the code, so you can just update the question and answers!
Duplicate the slide for Question 3 — it copies all the code, so you can just update the question and answers!
Write 1 final result message for each side
Use a Compare Number block (If…Else) to show which message appears
Test with different answers to check if scoring works
Use a Compare Number block to show which message appears.
If Side A > Side B → Fade
(in) Side A message
Test with different answers to check if scoring works
Add characters, backgrounds, and props.
🎮Code some silly animations or music if you have time.
Interactive Project Example for Students
Play through this lesson's example project created on Elementari. Use this example to guide and motivate your students.
Standards
CSTA K-12 Computer Science Standards (2017)
Algorithms & Programming
2-AP-10 - Use flowcharts and/or pseudocode to address complex problems as algorithms.
2-AP-13 - Decompose problems and subproblems into parts to facilitate the design, implementation, and review of programs.
2-AP-17 - Systematically test and refine programs using a range of test cases.
3A-AP-13 - Create prototypes that use algorithms to solve computational problems by leveraging prior student knowledge and personal interests.
3A-AP-16 - Design and iteratively develop computational artifacts for practical intent, personal expression, or to address a societal issue by using events to initiate instructions.
ISTE Student Standards
Creative Communicator
6b - Students create original works or responsibly repurpose or remix digital resources into new creations.
6d - Students publish or present content that customizes the message and medium for their intended audiences.
6c - Students communicate complex ideas clearly and effectively by creating or using a variety of digital objects such as visualizations, models or simulations.
Computational Thinker
5a - Students formulate problem definitions suited for technology-assisted methods such as data analysis, abstract models and algorithmic thinking in exploring and finding solutions.
Innovative Designer
4a - Students know and use a deliberate design process for generating ideas, testing theories, creating innovative artifacts or solving authentic problems.
4d - Students exhibit a tolerance for ambiguity, perseverance and the capacity to work with open-ended problems.
4c - Students develop, test and refine prototypes as part of a cyclical design process.
4b - Students select and use digital tools to plan and manage a design process that considers design constraints and calculated risks.
AASL Standards
Inquire
I.A.2 - Recalling prior and background knowledge as context for new meaning
I.B.3 - Generating products that illustrate learning.
I.C.4 - Sharing products with an authentic audience.