Northcentral Technical College Introduction To Programming
10-152-310
Introduction to Programming with JavaScript NTC 10-152-310

Learning Plan 5 5.2 Assignment 2

# 5.2 Assignment 2

#### File: /Learning Plan 5/5.2assignment2.html

### Student

- Name:
- Section:
- Email:

## Part 1

1. Open this file in Firefox and Microsoft Visual Studio.
2. Add your name, section, and email
3. Open the file "/Learning Plan 5/jsFiles/5.2assignment2.js"
4. Locate the function named "assignment52_2Part1()".
5. Add code after the line: `// PART 1: YOUR CODE STARTS AFTER THIS LINE:` to complete the exercise.

### Part 1 Problem Statement

> Write a program that loops one thousand times. Add all the even numbers and display the results. Add all the odd numbers and display the results.

- Sample Part 1 Output:

    Even Total: 249500
    Odd Total:  250000

### Part 1 Program Planning Lists

- In the following pre tag, write the three planning lists based on the verbs and nouns you see in the problem statement.

    The List of Input Variables:

    The List of Output Variables:

    The Process Checklist:

### Part 1 Test Plan

    TEST PLAN:

    Test Case 1:
        Inputs:

        Expected Results:

    Test Case 2:
        Inputs:

        Expected Results:

    Test Case 3:
        Inputs:

        Expected Results:

### Your Part 1 Output:

## Part 2

1. Locate the function named "assignment52_2Part2()".
2. Add code after the line: `// PART 2: YOUR CODE STARTS AFTER THIS LINE:` to complete the exercise.

### Part 2 Problem Statement

> Write a program that accesses the Employee Payroll Records Set. The program will output all the data for all employees whose pay for the week is or exceeds $1,000. The pay is calculated by multiplying Hourly Wage times Hours Worked.

- Sample Part 2 Output (Partial):

    103	Ethel Roselle	25	45	1125
    104	Barney Curry	30	35	1050
    106	Greg Statz	25	45	1125
    ...

### Part 2 Program Planning Lists

- In the following pre tag, write the three planning lists based on the verbs and nouns you see in the problem statement.

    The List of Input Variables:

    The List of Output Variables:

    The Process Checklist:

### Part 2 Test Plan

    TEST PLAN:

    Test Case 1:
        Inputs:

        Expected Results:

    Test Case 2:
        Inputs:

        Expected Results:

    Test Case 3:
        Inputs:

        Expected Results:

### Your Part 2 Output:

### Submitting your work

- Zip and submit 5.2 Assignment 2
- Don't forget to also zip and submit your JavaScript file 5.2assignment2.js.
- Make sure that both files are zipped and submitted together.