9/30/2013

BCS2233 OOP. Assignment 1

Write an algorithm (either flowchart or pseudocode) and java program for each of the following problem.

1. (Counting positive and negative numbers and computing the average of numbers) Write a program that reads an unspecified number of integers, determines how many positive and negative values have been read, and computes the total and average of the input values. Your program ends with the input 0.

2. (Summing a series) Write a program to sum the following series:





3. Write a test program that prompts the user to enter the investment amount (e.g., 1000) and the interest rate (e.g., 9%), and print a table that displays future value for the years from 1 to 30, as shown below:

The amount invested: 1000
Annual interest rate: 9%
Years       Future Value
  1          1093.8
  2          1196.41
...
 29         13467.25
 30         14730.57




No comments:

Cara download Installer windows 10 dalam format ISO

1. Jika anda bercadang untuk download windows 10 melalui website rasmi windows - pilihan untuk download dalam format ISO tidak di berikan.  ...