CS 260. Homework 5. Fall 2017. Due: November 3, 2017. T

Added on - 16 Sep 2019

  • Dissertation

    type

  • 2

    pages

  • 587

    words

  • 48

    views

  • 0

    downloads

Showing pages 1 to 1 of 2 pages
CS 260 Homework 5Fall 2017Due: November 3, 2017This is an individual assignment – design, code and debug your own projectAs always, you may seek assistance from the instructor1) Make corrections to Homework 4Make sure you are getting the correct answersChange code based on instructor feedback2) Modify Homework 4 (Payroll) to add the following elements:Edit the first and last namesoChange the first letter to capital and all other letters to lower caseAdd a SortedList to your program – the Key will be a department number and the Value will be adepartment name.Add the following data to the SortedList (It’s easiest to initialize to these values when you declareit)14Sales18Human Resources23Marketing29Research and Development34Customer Service37Finance51Production52Legal66Logistics73Purchasing75Information TechnologyAdd aListBox or ComboBoxto your form to hold thedepartment numberFill the ListBox or ComboBox withJUST the department numbersfrom the SortedListoUsing a loop, grab just the keys from the SortedList and add to the ListBox or ComboBoxoDo nothand type the department numbers into the properties windowValidate InputoUse the validation functions from the textbook – IsPresent, IsDecimal, IsWithinRange, etc.oWrite one IsValidData function withCompound conditions in a single return statement(asshown in book –bottom of page 225)oValidations:First NamePresentLast NamePresentHours workedPresent (not empty), Double, >=0, <=60Pay ratePresent, Decimal, >0, <= 99.99YTD GrossPresent, Decimal, >=0, <= 999,999.99AllowancesPresent, Integer, >= 0, <= 20Your organization has branches in several states. Each state has its own state tax rate. Createtwoarrays(parallel arrays) – one for state names (string) and one for state tax rates (double) (seebelow)oMichigan4.25%oIndiana3.23%oIllinois4.95%I would not use constants for tax rates, since youoSouth Dakota0.0%may have up to 50 in the futureoColorado4.63%
desklib-logo
You’re reading a preview
card-image

To View Complete Document

Become a Desklib Library Member.
Subscribe to our plans

Unlock This Document