Review Assignment - PHP Temperature Assignment

"The Temperature Assignment"

For this assignment, you will use some of the skills picked up in our last class.

What I'd like you to do is to programmatically create a celsius/Fahrenheit conversion table with PHP, which will ultimately look somewhat like the following:

0 degrees F is equivalent to - 17.7 C, which is cold
1 degrees F is equivalent to -17.2 C, which is cold
76 degrees F is equivalent to  22.2 C, which is nice
100 degrees F is equivalent to 37.77 C, which is hot

It should have AT LEAST 100 lines/entries and should have at least 3 "gradations" of temperature (hot, cold, warm, nice, etc) -- the names and amount are up to you, though they should be reasonable.

Decimal accuracy should be at least to the 10th for C. The "somewhat quick" conversion is fine, i.e.

F to C - Subtract 32, multiply by 5/9
C to F, Multiply by 9/5, add 32

To break it down, you'll need to think about the following tasks:

1) How to do math in PHP

2) How to do a finite loop, incrementing numbers in PHP

3) How to select an english description based on number input in PHP

You might want to tackle each of these seperately.

BONUS (I mean, for brownie points only, no extra credit unless I'm amazed)

Also, *color* each description accordingly; make "hot" red, "cold" blue, etc.


Give each line its OWN color (slightly different from the one before and after) , resulting in a smooth gradient from a deep blue for cold to a bright red for hot.

Procedural Tips

At this stage, I am assuming familiarity with
- Editing text files
- uploading/downloading to a server via FTP or SFTP or other means
- Some basic Linux shell familiarity, if desired

I am aware that this may not be the case for many of you, this is why I'm putting the due date a few weeks down the line and expecting feedback and discussion for those that may need help. For procedure, i.e. how to do everything above UNDER Procedural tips, you are absolutely free and encouraged to discuss with me privately via email or publicly in Discord or whatever means works for you. Once this is nailed down, I would prefer solo work for the main assignment, at least in the beginning, but we may revisit this limitation as well.

You may do your developing however you want; either perhaps locally then uploading, or even simply logging into torch via SSH and doing all your work there.

I am expecting final products to be hosted on Torch in the following fashion: (of course, substitute your own FSUID here)

For "turning in", simply post your url (or urls if you got fancy with the bonus) as text in Canvas.

Good luck, and I will update this as needed.