Ask Question, Ask an Expert

+61-413 786 465

info@mywordsolution.com

Ask Java Expert


Home >> Java

First at all, the program should be in java in JGRASP developer, the teacher requires that and while you writing the code you should pit comments for everything you do so the grader can follow the steps of the code. in the end of the work, it is necessary to write for me some information that used in the project like analysis, what kind of algorithm and data structure you used and why you use it? for efficiency and complexity! and you should test the program with different inputs or test cases !!

Text Processing Functions

INFX 141 / CS 121 • BOZHENA BIDYUK • UC IRVINE • WINTER 2016

This assignment is to be done individually; you may not use code written by your classmates. Use code found over the Internet at your own peril -- it may not do exactly what the assignment requests. If you do end up using code you find on the Internet, you must disclose the origin of the code. As stated in the collaboration guidelines, concealing the origin of a piece of code is plagiarism. Use Piazza for general questions whose answers can benefit you and everyone.

General Specifications

You may use Java, Python, or Scheme/Racket for this assignment. Java is the safest choice because the assignment is written with Java in mind and contains a variety of helpful Java resources. Using Python or Scheme will require you to translate these Java resources.

If you use Java, your solution must fill out the program skeleton provided. (i) Fill in each method according to its Javadoc specification. (ii) Feel free to create additional methods / classes where necessary.

If you don't use Java, you should produce a similar skeleton to start with and fill it out. You should also be very precise with instructions for how to run your program -- what programs are needed, what versions, and so on. If the TA can't run your program, your grade will reflect that.

You should test your code thoroughly, of course, with test data you create. You may exchange test data with anyone in the class. We will test your program with our own text files.

At points, this assignment may be underspecified (i.e., not fully describe what to do in every situation). In those cases, post your questions on Piazza or check with the TA. For minor issues, make your own assumptions and document them.

Part A: Utilities

Write a method that reads in a text file and returns a list of the tokens (preferably alphanumeric) in that file. Write a method to print out frequency results.

Package: ir.assignments.two.a
File: Utilities.java
Method: tokenizeFile(File)
Method: printFrequencies(List)

Part B: Word Frequencies
Count the total number of words and their frequencies in a token list.
Package: ir.assignments.two.b
File: WordFrequencyCounter.java
Method: computeWordFrequencies(ArrayList)

Part C: 2-grams
A 2-gram is two words that occur consecutively in a file. For example, "two words", "words that", and "that occur" are all 2-grams from the previous sentence.

Count the total number of 2-grams and their frequencies in a token list.
Package: ir.assignments.two.c
File: .TwoGramFrequencyCounter.java
Method: computeTwoGramFrequencies(ArrayList)

Part D: Palindromes
A palindrome is a words or phrase that reads. the same in both directions. For example, these are all palindromes: "kayak", "Do geese see god", "A man, a plan, a canal--Panama". Count the total number of palindromes and their frequencies in a text file.

Package: ir.assignments.two.d

File: PalindromeFrequencyCounter.java

Method: computePalindromeFrequencies(ArrayList)

Once you have implemented your palindrome counting algorithm, please perform a short analysis of its runtime complexity: Does it run in linear t.ime relative to the size of the input? polynomial time? exponential time? This analysis should go in the analysis.txt file in this package.

Attachment:- Assignment.zip

Java, Programming

  • Category:- Java
  • Reference No.:- M91606866
  • Price:- $75

Priced at Now at $75, Verified Solution

Have any Question?


Related Questions in Java

Assessment instructionsin this assessment you will design

Assessment Instructions In this assessment, you will design and code a simple Java application that defines a class, instantiate the class into a number of objects, and prints out the attributes of these objects in a spe ...

Can someone help me please with those question1what is the

Can someone help me please with those question 1:what is the best data type for student id datatime,currency,number,decimal 2:which relationshipis preferable? one to one,one to many,many to many 3:if you add table A's pr ...

Assessment socket programmingtaskwrite a java gui program

Assessment: Socket Programming Task Write a JAVA GUI program that would facilitate text chatting/exchanging between two or multiple computers over the network/internet, using the concept of JAVA socket programming. If yo ...

Project requirementsfor the problem described in the next

Project requirements For the problem described in the next section, you must do the following: 1. include your student ID at the end of all filenames for all java code files. Three classes have been identified in section ...

Object-oriented software development1 introduction 11

OBJECT-ORIENTED SOFTWARE DEVELOPMENT 1. Introduction 1.1 Assignment Requirement 1.2 Deliverables and Structure (what to submit) 1.3 Software Restrictions 1.4 How to score high... 1.5 Assumptions 2. System Requirements 2. ...

Chatbotscreate a small networked chat application that is

Chatbots Create a small, networked chat application that is populated by bots. Introduction On an old server park, filled with applications from the early days of the internet, a few servers still run one of the earliest ...

Solving 2nd degree equationsbull write the following java

Solving 2nd degree equations • Write the following Java methods • boolean real-sols(double a, double b, double c): it returns true if the 2nd degree equation ax2 + bx + c has real solutions • double solution1(double a, d ...

Assignment taskwrite a java console application that allows

Assignment task Write a java console application that allows the user to read, validate, store, display, sort and search data such as flight departure city (String), flight number (integer), flight distance (integer), fl ...

Assessment socket programmingtaskwrite a java gui program

Assessment: Socket Programming Task Write a JAVA GUI program that would facilitate text chatting/exchanging between two or multiple computers over the network/internet, using the concept of JAVA socket programming. If yo ...

Fundamentals of operating systems and java

Fundamentals of Operating Systems and Java Programming Purpose of the assessment (with ULO Mapping) This assignment assesses the following Unit Learning Outcomes; students should be able to demonstrate their achievements ...

  • 4,153,160 Questions Asked
  • 13,132 Experts
  • 2,558,936 Questions Answered

Ask Experts for help!!

Looking for Assignment Help?

Start excelling in your Courses, Get help with Assignment

Write us your full requirement for evaluation and you will receive response within 20 minutes turnaround time.

Ask Now Help with Problems, Get a Best Answer

Why might a bank avoid the use of interest rate swaps even

Why might a bank avoid the use of interest rate swaps, even when the institution is exposed to significant interest rate

Describe the difference between zero coupon bonds and

Describe the difference between zero coupon bonds and coupon bonds. Under what conditions will a coupon bond sell at a p

Compute the present value of an annuity of 880 per year

Compute the present value of an annuity of $ 880 per year for 16 years, given a discount rate of 6 percent per annum. As

Compute the present value of an 1150 payment made in ten

Compute the present value of an $1,150 payment made in ten years when the discount rate is 12 percent. (Do not round int

Compute the present value of an annuity of 699 per year

Compute the present value of an annuity of $ 699 per year for 19 years, given a discount rate of 6 percent per annum. As