Academic Integrity: tutoring, explanations, and feedback — we don’t complete graded work or submit on a student’s behalf.

NOTE: The completed code must pass in the following compiler. Please make absolu

ID: 3576443 • Letter: N

Question

NOTE: The completed code must pass in the following compiler. Please make absolutely sure it does before posting: http://codecheck.it/codecheck/files?repo=bj4cc&problem=ch09/c09_exp_9_103

PLEASE also make sure of the following:
-Post this as text, not as an image.
-Avoid making alterations to the original code unless necessary.
-Post the passing output- from the this compiler specifically- as evidence this code was accepted and passed.

~

Some objects can be doubled, for example a bank account. The result would be a bank account with twice the balance. Some objects can't be doubled. For example, there is no double of a dime coin—no twenty cent coin exists.

The Doublable interface specifies a method for making an object that is double of the current one. It should only be implemented by classes for which doubling makes sense.

Your job is to modify the Word class of chapter 6 (which is reproduced below, with the bugs fixed) so that it implements the Doublable interface. Doubling a word should repeat its text. For example,

should produce a Word object with text "JavaJava".

Complete the following code:

The following classes are used to check your work:

Explanation / Answer

Testers

Running WordTester.java

pass

//now the code