Ask Question, Ask an Expert

+1-415-315-9853

info@mywordsolution.com

Ask Java Expert


Home >> Java

Project Objective:

Effectively use the String, Character, and StringBuilder classes and associated methods.

prepare Java code to read and prepare data to and from a file

Deliverables:

a) Design, develop, test and document the Java application which reads data from the input file, processes data, and then prepares processed data to an output file

Specific functional requirements for this project:

a) The application must be run from command line using command line arguments to provide input and output filenames.

b) The application must display the suitable error message if user forgets to enter the input and output filenames at the command prompt or if the files are not found.

c) The application must open the file and read each line of the file.

d) For each line read, the application must find out the total number of characters in the line (including white-space characters), determine number of times the number 4 appears in the line, replace all occurrences of the string "this" with "That", and reverse the order of the characters in the line.

e) The output file must contain same number of lines as the input file with the following content for each line:

i) Total number of characters (including white-space characters) in the line

ii) Number of times the number 4 appeared in the line

iii) Reversed string (for ex, cats in the input file would be displayed as stac)

f) The items on each line in the output file should be separated by commas (for ex: for input line "this4cats", the output line should be "9,1,stac4tahT")

The application must close any open files before exiting.

Format:

Code Documentation and Style Requirements

The documentation requirement for all programming projects is one block comment at the top of the program containing the course name, the project number, your name, the date and platform/compiler that you used to develop the project. In addition, there must be at least one comment for each class in the program describing what that class does. Additional comments must be provided as essential to clarify the program.

Indentation should be consistent throughout the program. Variable and method names should be descriptive of the role of the variable or method. Single letter names should be avoided. All constants, except 0 and 1, should be named. Constant names should be all upper-case. Variable names should begin in lower-case, but subsequent words should be in title case (e.g., finalSpeed).

Separate compilation should be used in accordance with standard Java practice. Every class should be saved in a separate .java file.

Java, Programming

  • Category:- Java
  • Reference No.:- M94588

Have any Question? 


Related Questions in Java

Design your own java class that includes at least 3 data

Design your own Java Class that includes at least 3 data fields, 2 constructors and 4 methods. When designing your class, pick an object that you are familiar with and make it your own, realistic, yet simple design with ...

Develop a console program for java on microsoft notepad

Develop a console program for JAVA on Microsoft notepad that simulates a section of a restaurant menu. Each item will have a different price and your program should define at least ten items. You will need to obtain an o ...

Java programmingwrite a java application using netbeans

JAVA PROGRAMMING Write a Java application using NetBeans Integrated Development Environment (IDE) that calculates the total annual compensation of a salesperson. Consider the following factors: • A salesperson will earn ...

Write a java program non-gui preferred to demonstrate the

Write a Java program (non-GUI preferred) to demonstrate the use of Iterator. The program should allow a user to do the following: Allow the reading of a collection of animal objects from an external file. Output on scree ...

This assignment consists of two sectionsbulljava program

This assignment consists of two sections: • Java program file(s) • A screenshot of the execution and source code of your Java program Label each file name according to the section of the assignment for which it is writte ...

Javapizzacontactlistat the beginning of all your programs

JavaPizza ContactList At the beginning of all your programs, put a comment box that includes the program name, your name, and a brief description of the program. Example: /************************************************ ...

Questions for java programing answer each question with at

QUESTIONS FOR JAVA PROGRAMING (answer each question with at least 5 sentences) 1. Discuss why it is necessary to use repetitive and selective statement. Use segment codes to demonstrate your understanding. Explain why yo ...

Program 1objectivethis program assignment is provided to

Program 1 Objective: This program assignment is provided to let the students know how to handle threads and enhance system availability on a multiprocessor or multicore environment. A single process is supposed to create ...

Write a java program non-gui preferred to demonstrate the

Write a Java program (non-GUI preferred) to demonstrate the use of an ArrayList. The program should allow a user to do the following: Add, edit, delete different types of animals Select an animal, and the corresponding c ...

1how does java support the concept of encapsulation2

1. How does Java support the concept of encapsulation? 2. Describe the difference between an object and a class. 3. What is the difference between the contents of a Java variable of a primitive type and a Java variable o ...

  • 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

Section onea in an atwood machine suppose two objects of

SECTION ONE (a) In an Atwood Machine, suppose two objects of unequal mass are hung vertically over a frictionless

Part 1you work in hr for a company that operates a factory

Part 1: You work in HR for a company that operates a factory manufacturing fiberglass. There are several hundred empl

Details on advanced accounting paperthis paper is intended

DETAILS ON ADVANCED ACCOUNTING PAPER This paper is intended for students to apply the theoretical knowledge around ac

Create a provider database and related reports and queries

Create a provider database and related reports and queries to capture contact information for potential PC component pro

Describe what you learned about the impact of economic

Describe what you learned about the impact of economic, social, and demographic trends affecting the US labor environmen