Posted By

skyhook322 on 12/15/09


Tagged


Versions (?)

assignment3


 / Published in: Pseudocode
 

main()

continueToEnter = “y” Declare Integer nonGreen[12] Declare Integer green[12] Declare Integer savings[12] months = [’January’, ‘February’, ‘March’, ‘April’, ‘May’, ‘June’, ‘July’, ‘August’, ‘September’, ‘October’, ‘November’, ‘December’]

def getGreen()

input (‘Enter the amount for”+months[0])

def calculations()

savings[1] = nonGreen[1] – green[1] savings[2] = nonGreen[2] – green[2] savings[3] = nonGreen[3] – green[3] savings[4] = nonGreen[4] – green[4] savings[5] = nonGreen[5] – green[5] savings[6] = nonGreen[6] – green[6] savings[7] = nonGreen[7] – green[7] savings[8] = nonGreen[8] – green[8] savings[9] = nonGreen[9] – green[9] savings[10] = nonGreen[10] – green[10] savings[11] = nonGreen[11] – green[11] savings[12] = nonGreen[12] – green[12]

  1. main()
  2.  
  3. continueToEnter = �y�
  4. Declare Integer nonGreen[12]
  5. Declare Integer green[12]
  6. Declare Integer savings[12]
  7. months = [�January�, �February�, �March�, �April�, �May�, �June�, �July�, �August�, �September�, �October�, �November�, �December�]
  8.  
  9.  
  10. def getGreen()
  11.  
  12. input (�Enter the amount for�+months[0])
  13.  
  14. def calculations()
  15.  
  16. savings[1] = nonGreen[1] � green[1]
  17. savings[2] = nonGreen[2] � green[2]
  18. savings[3] = nonGreen[3] � green[3]
  19. savings[4] = nonGreen[4] � green[4]
  20. savings[5] = nonGreen[5] � green[5]
  21. savings[6] = nonGreen[6] � green[6]
  22. savings[7] = nonGreen[7] � green[7]
  23. savings[8] = nonGreen[8] � green[8]
  24. savings[9] = nonGreen[9] � green[9]
  25. savings[10] = nonGreen[10] � green[10]
  26. savings[11] = nonGreen[11] � green[11]
  27. savings[12] = nonGreen[12] � green[12]

Report this snippet  

You need to login to post a comment.