- Jul 9, 2003
- 291
- 0
- 0
I need help in writing a program in either Java or Perl on file input and comparing two files and their lines of text.
For example, if file1 has:
I like oranges
I like apples
I like pears
and file2 has:
I like apples
I like guavas
I like oranges
then running the program with this command:
samelines file1 file2
Should produce the output:
I like apples
I like oranges
Can somebody help? Thanks in advance.
For example, if file1 has:
I like oranges
I like apples
I like pears
and file2 has:
I like apples
I like guavas
I like oranges
then running the program with this command:
samelines file1 file2
Should produce the output:
I like apples
I like oranges
Can somebody help? Thanks in advance.