2551.p5.Spring2010

2551.p5.Spring2010 - COP 2551 Introduction to OOP Program#5...

Info iconThis preview shows pages 1–2. Sign up to view the full content.

View Full Document Right Arrow Icon
COP 2551 – Introduction to OOP Program #5 Due: Tuesday, 23 April 2010 Using NetBeans 6.7.1, you are to write a Java program using OOP principles to accommodate the following functionality Using the input file Countries.txt, you are to build a 4 by X array of integers, average the numbers in each row and display the array and averages. Each record in the input file has two fields of interest to you: the region number and the population. (You will need a substring to extract those two numbers, as in Program 4) Task 1: Build a Two-Dimensional Array . Build a 4by X array such that each row contains a list of integers for ‘that’ region. Specifically, row 1 would have six columns: 480000 720000 500000 100000 1360000 and 15000 namely arrayName (0,0), (0,1), (0,2), etc. that is, all the populations from countries that were in region 1. Your second row will have all the populations from those countries that are in region 2, etc. Since there are four regions, your two-dimensional array will have four rows. The number of columns depends on the number of countries
Background image of page 1

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
Image of page 2
This is the end of the preview. Sign up to access the rest of the document.

This note was uploaded on 07/26/2011 for the course COP 2551 taught by Professor Roggio,r during the Summer '08 term at UNF.

Page1 / 2

2551.p5.Spring2010 - COP 2551 Introduction to OOP Program#5...

This preview shows document pages 1 - 2. Sign up to view the full document.

View Full Document Right Arrow Icon
Ask a homework question - tutors are online