Skip to content

Commit 700928e

Browse files
committed
#997: description update
1 parent 0f53fba commit 700928e

File tree

1 file changed

+7
-7
lines changed

1 file changed

+7
-7
lines changed

c-sharp/Problems/arrays-and-hashing/FindTheTownJudge.cs

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -4,36 +4,36 @@
44
**
55
* In a town, there are n people labeled from 1 to n.
66
* There is a rumor that one of these people is secretly the town judge.
7-
*
7+
*
88
* If the town judge exists, then:
99
* 1. The town judge trusts nobody.
1010
* 2. Everybody (except for the town judge) trusts the town judge.
1111
* 3. There is exactly one person that satisfies properties 1 and 2.
12-
*
12+
*
1313
* You are given an array trust where trust[i] = [ai, bi]
1414
* representing that the person labeled ai trusts the person labeled bi.
15-
*
15+
*
1616
* If a trust relationship does not exist in trust array,
1717
* then such a trust relationship does not exist.
18-
*
18+
*
1919
* Return the label of the town judge if the town judge exists and can be identified,
2020
* or return -1 otherwise.
2121
*
2222
* Example 1:
2323
* Input: n = 2, trust = [[1,2]]
2424
* Output: 2
25-
*
25+
*
2626
* Example 2:
2727
* Input: n = 3, trust = [[1,3],[2,3]]
2828
* Output: 3
29-
*
29+
*
3030
* Example 3:
3131
* Input: n = 3, trust = [[1,3],[2,3],[3,1]]
3232
* Output: -1
3333
*
3434
* Constraints:
3535
* • 1 <= n <= 1000
36-
* • 0 <= trust.length <= 104
36+
* • 0 <= trust.length <= 10^4
3737
* • trust[i].length == 2
3838
* • All the pairs of trust are unique.
3939
* • ai != bi

0 commit comments

Comments
 (0)