Interactive Pathways
Learn by doing with our Jupyter-style interactive notebooks. Write code, run it, and see results instantly!
JavaScript Basics
An interactive introduction to JavaScript programming.
# Welcome to JavaScript Basics
In this pathway, you'll learn the fundamentals of JavaScript - the language that brings websites to life!
> "For I know the plans I have for you," declares the Lord, "plans to prosper you and not to harm you, plans to give you hope and a future." — Jeremiah 29:11
Let's begin our coding journey!
## 1. Variables: Storing Truth
Variables are like containers that hold information. In JavaScript, we can create variables using let, const, or var.
- let - for values that might change
- const - for values that stay the same (like God's love!)
- var - the old way (still works, but prefer let and const)
## 2. Your Turn!
Now it's your turn to practice. Create a variable called myName and log a greeting to the console.
Expected output: Hello, [Your Name]!
## 3. Numbers and Math
JavaScript can do math! Let's explore some basic operations.
| Operator | Description | Example |
|----------|-------------|---------|
| + | Addition | 5 + 3 = 8 |
| - | Subtraction | 10 - 4 = 6 |
| | Multiplication | 6 7 = 42 |
| / | Division | 20 / 4 = 5 |
## 4. Functions: Calling on the Lord
Functions are reusable blocks of code. Just like we can call on God anytime, we can call functions whenever we need them!
## 5. Challenge: Create Your Own Function
Now create a function called bless that takes a name and returns a blessing!
Example: bless("Sarah") should output "May God bless you, Sarah!"
## Congratulations!
You've completed the JavaScript Basics pathway! You learned:
1. ✅ Variables - storing data with let and const
2. ✅ Console.log - outputting messages
3. ✅ Math - performing calculations
4. ✅ Functions - creating reusable code
> "I can do all things through Christ who strengthens me." — Philippians 4:13
Keep coding for His glory!
How to Use Pathways:
- • Read the markdown cells for explanations and context
- • Edit the code cells to experiment with JavaScript
- • Run cells with the ▶ button or "Run All" to execute
- • Reset cells with ↺ if you want to start over
- • Hints are available with the 💡 button when you're stuck
- • Complete all code cells to finish the pathway!
What Makes Pathways Special?
Context Preserved
Variables and functions from earlier cells are available in later cells. Build up your code step by step!
Guided Learning
Some cells check your output against expected results. Get immediate feedback on your code!
Rich Explanations
Markdown cells include formatted text, code examples, tables, and Scripture references.
Safe Experimentation
Reset any cell to start fresh. Your browser runs the code safely without affecting anything else.
More Ways to Learn
Pathways are just one way we teach coding. Explore our other learning tools!