Premium Only Content
Leetcode solving: 997. Find the Town Judge
Leetcode solving: 997. Find the Town Judge
Please subscribe to my channel
In a town, there are n people labelled from 1 to n. There is a rumor that one of these people is secretly the town judge.
If the town judge exists, then:
The town judge trusts nobody.
Everybody (except for the town judge) trusts the town judge.
There is exactly one person that satisfies properties 1 and 2.
You are given trust, an array of pairs trust[i] = [a, b] representing that the person labelled a trusts the person labelled b.
If the town judge exists and can be identified, return the label of the town judge. Otherwise, return -1.
##############
My other Leetcode solving videos (easy)
https://www.youtube.com/playlist?list=PLg9w7tItBlZt4oUpNyWU_0rOItlScu1_d
Leetcode solving videos (Medium):
https://www.youtube.com/playlist?list=PLg9w7tItBlZvMGxy-y1eXURPD6Ao6kkzA
Leetcode solving videos (Hard):
https://www.youtube.com/playlist?list=PLg9w7tItBlZt4JQmlkGD3M5idZn14NyL6
############
-
LIVE
Wendy Bell Radio
4 hours agoNothing To See Here
9,192 watching -
2:12:18
TheDozenPodcast
20 hours agoIslam vs Christianity: Bob of Speakers' Corner
31.1K12 -
14:36
The StoneZONE with Roger Stone
1 day agoRoger Stone Delivers Riveting Speech at Turning Point’s AMFEST 2024 | FULL SPEECH
40.4K10 -
18:59
Fit'n Fire
10 hours ago $2.23 earnedZenith ZF5 The Best MP5 Clone available
7.02K1 -
58:34
Rethinking the Dollar
19 hours agoTrump Faces 'Big Mess' Ahead | RTD News Update
13.2K5 -
5:35
Dermatologist Dr. Dustin Portela
19 hours ago $1.25 earnedUnboxing Neutrogena PR Box: Skincare Products and Surprises!
11.5K2 -
11:20
China Uncensored
18 hours agoCan the US Exploit a Rift Between China and Russia?
27.2K15 -
2:08:48
TheSaltyCracker
13 hours agoLefty Grifters Go MAGA ReeEEeE Stream 12-22-24
222K653 -
1:15:40
Man in America
16 hours agoThe DISTURBING Truth: How Seed Oils, the Vatican, and Procter & Gamble Are Connected w/ Dan Lyons
130K126 -
6:46:07
Rance's Gaming Corner
18 hours agoTime for some RUMBLE FPS!! Get in here.. w/Fragniac
165K4