Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions exercises/practice/pig-latin/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -22,3 +22,7 @@ test {
events = ["passed", "failed", "skipped"]
}
}

tasks.named("compileTestJava").configure {
dependsOn("copyTestsFilteringIgnores")
}
Comment on lines +25 to +28
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This change should no longer be needed, as the Gradle configuration was fixed in #2339

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Could you fix the formatting of this stub?

  • Make sure the import section and the class definition is separated by a new line
  • Make sure the file ends with a final new line

Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
/*
import java.lang.String;
public class PigLatinTranslator {
public PigLatinTranslator() {
throw new UnsupportedOperationException("Please implement the PigLatinTranslator constructor.");
}

Since this exercise has a difficulty of > 4 it doesn't come
with any starter implementation.
This is so that you get to practice creating classes and methods
which is an important part of programming in Java.

Please remove this comment when submitting your solution.

*/
public String translate(String text) {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I would prefer the method parameter to be named sentence like in the example implementation. It gives the student a small hint in terms of what to expect in terms of input.

throw new UnsupportedOperationException("Please implement the PigLatinTranslator.translate method");
}
}