Assignment

Your Task

Write a php program Use at least three of these

  • Functions
  • While Loops
  • For Loops
  • Input/Output
  • Arrays
  • Conditionalsclass

findirfin.dev/md/

Previous Lessons

go here to get reminders https://drive.google.com/drive/u/0/folders/1H0BQTHqyWT_w3m2FBkvlybV-VRbYVGPt

Examples

1. Functions

<?php
function greet($name) {
  return "Hello, " . $name . "!";
}

echo greet("Alice"); // Output: Hello, Alice!
?>

2. While Loops

<?php
$i = 1;
while ($i <= 5) {
  echo $i . " ";
  $i++;
}
// Output: 1 2 3 4 5
?>

3. For Loops

<?php
for ($i = 1; $i <= 5; $i++) {
  echo $i . " ";
}
// Output: 1 2 3 4 5
?>

4. Input/Output

Read more

in class

my deepest darkest secrets

dolphins are better than pigs

Read more

How I sync my obsidian vault for free

I’m just going to put my summary here, It took me a few days to figure out the best way to do this. I tried many, many ways of doing this, and looked through quite a lot of material online and eventually landed on this

Syncing through git is the best way to sync obsidian. Through platforms like github there aren’t any size limits, and if you try hard enough you can get it to work everywhere.

Read more