# JavaScript Fundamentals

JavaScript is a programming language that enables interactive web pages and is an essential part of web applications.

## Variables
```javascript
// Variable declaration
let name = "John";
const age = 30;
var isStudent = true;
```

## Functions
```javascript
// Function declaration
function greet(name) {
    return "Hello, " + name + "!";
}

// Arrow function
const multiply = (a, b) => a * b;
```

## Control Structures
```javascript
// Conditional statements
if (age >= 18) {
    console.log("Adult");
} else {
    console.log("Minor");
}

// Loops
for (let i = 0; i < 5; i++) {
    console.log(i);
}
```

## DOM Manipulation
```javascript
// Selecting elements
const element = document.getElementById("myId");

// Modifying content
element.innerHTML = "New content";

// Adding event listeners
element.addEventListener("click", function() {
    alert("Element clicked!");
});
```