Refactor Code Style (#4151)

This commit is contained in:
Saurabh Rahate
2023-04-15 13:55:54 +05:30
committed by GitHub
parent 1ce907625b
commit 1dc388653a
100 changed files with 293 additions and 319 deletions

View File

@ -4,7 +4,7 @@ import java.util.*;
class PageRank {
public static void main(String args[]) {
public static void main(String[] args) {
int nodes, i, j;
Scanner in = new Scanner(System.in);
System.out.print("Enter the Number of WebPages: ");
@ -24,14 +24,14 @@ class PageRank {
p.calc(nodes);
}
public int path[][] = new int[10][10];
public double pagerank[] = new double[10];
public int[][] path = new int[10][10];
public double[] pagerank = new double[10];
public void calc(double totalNodes) {
double InitialPageRank;
double OutgoingLinks = 0;
double DampingFactor = 0.85;
double TempPageRank[] = new double[10];
double[] TempPageRank = new double[10];
int ExternalNodeNumber;
int InternalNodeNumber;
int k = 1; // For Traversing