Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Assignment Information Instructions: USE JAVA The three attached files contain similar data. Test is the small file that can be used to check your results.

Assignment Information
Instructions: USE JAVA
The three attached files contain similar data. Test is the small file that can be used to check your results. Your code should only access one file at a time.
We want to find the unique "links" to the first element in the file. You can think of the first 3 numbers as the web page and the next 3 numbers as a link to it. We want to write code that provides the number of unique links. You should not use contains or any other method to determine if a link has been added. We would like to know how many lines are in the selected file when we run the program. You should use an Iterator to print the results.
Sample output for Test.txt:
Number unique elements 3
Total number of lines 7
Unique links
0002
0011
0022

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Database Design And SQL For DB2

Authors: James Cooper

1st Edition

1583473572, 978-1583473573

Students also viewed these Databases questions