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 larry.page

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 textrn”;

BufferedWriter output = null;

try {

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

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

output.write(text);

} catch ( IOException e ) {

e.printStackTrace();

} 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 ]
        e.g.
        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
        Output:
        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]
[Note:
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
.
.







Place your order
(550 words)

Approximate price: $22

Calculate the price of your order

550 words
We'll send you the first draft for approval by September 11, 2018 at 10:52 AM
Total price:
$26
The price is based on these factors:
Academic level
Number of pages
Urgency
Basic features
  • Free title page and bibliography
  • Unlimited revisions
  • Plagiarism-free guarantee
  • Money-back guarantee
  • 24/7 support
On-demand options
  • Writer’s samples
  • Part-by-part delivery
  • Overnight delivery
  • Copies of used sources
  • Expert Proofreading
Paper format
  • 275 words per page
  • 12 pt Arial/Times New Roman
  • Double line spacing
  • Any citation style (APA, MLA, Chicago/Turabian, Harvard)

Our guarantees

Delivering a high-quality product at a reasonable price is not enough anymore.
That’s why we have developed 5 beneficial guarantees that will make your experience with our service enjoyable, easy, and safe.

Money-back guarantee

You have to be 100% sure of the quality of your product to give a money-back guarantee. This describes us perfectly. Make sure that this guarantee is totally transparent.

Read more

Zero-plagiarism guarantee

Each paper is composed from scratch, according to your instructions. It is then checked by our plagiarism-detection software. There is no gap where plagiarism could squeeze in.

Read more

Free-revision policy

Thanks to our free revisions, there is no way for you to be unsatisfied. We will work on your paper until you are completely happy with the result.

Read more

Privacy policy

Your email is safe, as we store it according to international data protection rules. Your bank details are secure, as we use only reliable payment systems.

Read more

Fair-cooperation guarantee

By sending us your money, you buy the service we provide. Check out our terms and conditions if you prefer business talks to be laid out in official language.

Read more

Get 15% OFF on your FIRST order. Use the coupon code: new15