Dr. Fatema Nafa

AI Learning Toolkit

EECE 2140 - Generate, Understand, Validate, Debug, and Review AI-Generated Code

Instructor Configuration Panel

Upload a JSON configuration file to change debug challenges and code review scenarios. Students will not see this panel.

Student Info
Session: Not started - fill in your info and begin
1Pseudocode Design
2Prompt Engineering
3Generate
4Understand
5Validate
Assignment Question

Loading question...

Hints
    Course Outcomes Addressed

      Pseudocode Design: Think Before You Prompt

      Now that you have read the question, design your solution below. Writing pseudocode forces you to think through the logic before touching any AI tool.

      Step 1

      Prompt Engineering: Convert Pseudocode to AI Prompt

      Now translate your pseudocode design into a precise prompt for the AI tool. The better your pseudocode, the better the AI output. Your pseudocode is shown below for reference.

      Your Pseudocode (from Pseudocode Design):
      
        
      Your Constructed Prompt (auto-generated from pseudocode and requirements):
      Fill in the fields above and click Build Prompt...
      Step 2

      Generate: Paste Your Prompt and AI Output

      Paste the exact prompt you gave the AI tool and the code it generated. Do not modify the AI output here.

      Compare: Does the AI output match your pseudocode?
      
          
          
          
          
        
      Step 3

      Understand: Explain What the Code Does

      Prove that you understand the AI-generated code by explaining it in your own words. Compare it against your original pseudocode.

      Step 4

      Validate: Test, Modify, and Assess

      Test the AI code with at least 3 test cases (including edge cases from your pseudocode). Document what you changed.

      5/10
      Student Info
      Session: Not started - click Start to begin timing
      Debug the AI Challenge

      Find and Fix Bugs in AI-Generated Code

      Using default challenges

      The code below was generated by an AI tool and contains bugs. Find each bug, identify the line, and write the corrected code.

      00:00
      Line #Error TypeCorrected Code
      Student Info
      Session: Not started
      Code Review Simulator

      Compare AI-Generated vs Human-Written Code

      Using default scenario

      Below are two solutions to the same problem. Review both critically and answer the questions.