The attached file | Computer Science homework help


1) The attached file (attendance.txt) is a list of email addresses you collected for a conference your company hosted. Create a program that will parse each email address by its name and company. (Note: email parser object is attached). The company should be sorted in the first column and the person’s name associated with the company should be sorted in the second column; separated with tab character. (first sort is by company; secondary sort is by firstname.lastname). Sample output is listed below:

amzn bob.freed

amzn caitlin.thomas

amzn edward.flak

amzn jill.bennet

amzn mike.reade

fb chris.booker

fb fred.smith

fb jane.bland

fb megan.hill

goog gary.teafer

goog john.kohl


goog phil.heal

goog zara.war

msft alan.gret

msft darlene.neddle

msft don.shaffer

msft ken.smith

msft sue.flemming

orcl  heidi.opal

orcl  john.voy

orcl  larry.lee

orcl  mark.lite

2) Create a histogram on the number of attendees per company for the conference. (can be in same program as #1)

3) Check if bill.gates attended the conference.Output that Bill Gates attended conference. (can be in same program as #1)

4) Create an output text file for the output above so that it can be imported in Excel for further analysis. One method of code to write text to an output file: (can be in same program as #1)

String text = “my text\r\n”;

BufferedWriter output = null;

try {

File file = new File(“example.txt”);

output = new BufferedWriter(new FileWriter(file));


} catch ( IOException e ) {


} finally {

if ( output != null ) {

output.close(); // need to close file to write to a file




Assignment #4:

1)  Write a program(main() method) that reads an arbitrary number of integers that are in the range of 0 to 50 inclusive and counts how many occurrences of each are entered.  After all inputs have been processed, print only the values that have an occurrence of greater than zero.  Also, print the number of occurrences next to the value. [use arrays and indexing ]
        Enter a value between 0 and 50 [ -1 to end ]: 10
        Enter a value between 0 and 50 [ -1 to end ]: 2
        Enter a value between 0 and 50 [ -1 to end ]: 30
        Enter a value between 0 and 50 [ -1 to end ]: 10
        Enter a value between 0 and 50 [ -1 to end ]: 3
        Enter a value between 0 and 50 [ -1 to end ]: 10
        Enter a value between 0 and 50 [ -1 to end ]: 30
        Enter a value between 0 and 50 [ -1 to end ]: 2
        Enter a value between 0 and 50 [ -1 to end ]: -1
        The value of 2 has 2 occurrences.
        The value of 3 has 1 occurrences.
        The value of 10 has 3 occurrences.
        The value of 30 has 2 occurrences.
2)  Write a program (main() method) that reads, from the terminal (screen), sequence of names and postal (ZIP) codes for individuals.  Store the data in an object designed to store a first name (String), last name (String), and postal code (int).  Assume each line of input will contain two strings followed by an integer value, each separated by a tab character.  Users will type “quit” when they have completed input entry.  Print the output of the input values by the user to the screen.
[use ArrayList to store object]
1)  create an object that will store the first name (String), last name (String), postal code (int)
2)  use ArrayList to store object]
C:\Enter Input {first_name<tab>last_name<tab>zip_code}:
Bill     Smith   10002
Enter Input {first_name<tab>last_name<tab>zip_code}:
Jane     Dome    11354
Enter Input {first_name<tab>last_name<tab>zip_code}:
3)  Revise #2 problem to read a list of inputs from a file.  The input file will contain two strings followed by an integer.
Input file:
Bill     Smith   10002
Jill     Ryan    11120
Robert   Johnson 11122
Calculate your order
Pages (275 words)
Standard price: $0.00
Client Reviews
Our Guarantees
100% Trustworthy
Information about client is confidential and never disclosed to third parties.
Original Writing
We complete all papers from scratch. You can get a plagiarism report.
Timely Delivery
No missed deadlines – 97% of assignments are completed in time.
Money Back
If you're confident that a writer didn't follow your order details, ask for a refund.

Calculate the price of your order

You will get a personal manager and a discount.
We'll send you the first draft for approval by at
Total price:
Power up Your Academic Success with the
Team of Professionals. We’ve Got Your Back.
Power up Your Study Success with Experts We’ve Got Your Back.