mirror of
https://github.com/TheAlgorithms/Java.git
synced 2025-07-24 04:54:21 +08:00
style: enable RedundantModifier
in checkstyle (#5140)
This commit is contained in:
@ -61,7 +61,7 @@ class Graph {
|
||||
public final String v1, v2;
|
||||
public final int dist;
|
||||
|
||||
public Edge(String v1, String v2, int dist) {
|
||||
Edge(String v1, String v2, int dist) {
|
||||
this.v1 = v1;
|
||||
this.v2 = v2;
|
||||
this.dist = dist;
|
||||
@ -79,7 +79,7 @@ class Graph {
|
||||
public Vertex previous = null;
|
||||
public final Map<Vertex, Integer> neighbours = new HashMap<>();
|
||||
|
||||
public Vertex(String name) {
|
||||
Vertex(String name) {
|
||||
this.name = name;
|
||||
}
|
||||
|
||||
@ -147,7 +147,7 @@ class Graph {
|
||||
/**
|
||||
* Builds a graph from a set of edges
|
||||
*/
|
||||
public Graph(Edge[] edges) {
|
||||
Graph(Edge[] edges) {
|
||||
graph = new HashMap<>(edges.length);
|
||||
|
||||
// one pass to find all vertices
|
||||
|
@ -176,7 +176,7 @@ public class KochSnowflake {
|
||||
|
||||
double x, y;
|
||||
|
||||
public Vector2(double x, double y) {
|
||||
Vector2(double x, double y) {
|
||||
this.x = x;
|
||||
this.y = y;
|
||||
}
|
||||
|
@ -25,7 +25,7 @@ class QueueWithStack {
|
||||
/**
|
||||
* Constructor
|
||||
*/
|
||||
public QueueWithStack() {
|
||||
QueueWithStack() {
|
||||
this.inStack = new Stack<>();
|
||||
this.outStack = new Stack<>();
|
||||
}
|
||||
|
@ -11,7 +11,7 @@ public class TopKWords {
|
||||
|
||||
private String fileName;
|
||||
|
||||
public CountWords(String fileName) {
|
||||
CountWords(String fileName) {
|
||||
this.fileName = fileName;
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user