Think-Design-Write Test-Code
5 Days
- Description
Congratulations! You have just been hired for a junior programming position with Mighty Corp.
Your boss comes to you and gives you your first assignment. It is to learn JavaScript, since it was not on your resume, in preparation for working on the iPhone hybrid application team.
Being wise you start at the beginning. You decide to start with the basics of nearly all languages, variables and operations and how to implement an if-then-else conditional statement.
You decide to create a simple, small, hard-coded calculator.
- Deliverables
- A test matrix that shows inputs and the expected output for those inputs.
- Working code that assigns two variables and display the sum, difference, product, and quotient of the two variables and if the result is greater, less than, or equal to 15. The values assigned to the variables should be changed and the calculations and display of data must be done again.
- Working code that concatenates three hard-coded strings and displays the resultant string.
- Resources
- Variables
- Operators
- Comparitors
- The if-then-else Control Statement
- Displaying Results
- Definitions:
- Variable – a storage location for values. The value assigned to the variable can be changed any number of times but a variable can only refer to one value at a time.