-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathFriend.java
More file actions
36 lines (30 loc) · 929 Bytes
/
Friend.java
File metadata and controls
36 lines (30 loc) · 929 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
// Kevin Mattappally
// Davis Fairchild
// Ryan Hays
// How we are going to implement the best freind chain
// 1. We will implement the best friend chain by utilizing the
// Dijkstra's algorith
// Here are our two killer features:
// 1. Finding Mutual Friends between two users
// a. To find the mutual friends, we would be using
// the brute force algorithm.
// 2. Finding the most popular / best friend
// a. To find the most popular friend, we would find the friend
// in the graph with the highest overall average friend rating.
public class Friend {
private String name;
private int rank;
public Friend(String name, int rank) {
this.name = name;
this.rank = rank;
}
public String getName() {
return name;
}
public int getRank() {
return rank;
}
public String toString() {
return name + ": " + rank;
}
}