b001
b001
  • 119
  • 32 600 671
How Algorithms Find Shortest Paths (Dijkstra's & Bellman-Ford)
To further enhance your computer science knowledge, go to brilliant.org/b001 to start your 30-day free trial and get 20% off an annual premium subscription.
If you want to experiment with the algorithms yourself, I've included some Python scripts on my Patreon: www.patreon.com/b001io
💬 Discord: discord.gg/jA8SShU8zJ
🐦 Follow me on Twitter: b001io
🔗 More links: linktr.ee/b001io
zhlédnutí: 22 738

Video

Dijkstra's Hidden Prime Finding Algorithm
zhlédnutí 159KPřed 4 měsíci
⭐ Join my Patreon: www.patreon.com/b001io 💬 Discord: discord.gg/jA8SShU8zJ 🐦 Follow me on Twitter: b001io 🔗 More links: linktr.ee/b001io Outro background music: Mystic Mountain by Purrple Cat | purrplecat.com Music promoted by www.free-stock-music.com Creative Commons / Attribution-ShareAlike 3.0 Unported (CC BY-SA 3.0) creativecommons.org/licenses/by-sa/3.0/deed.en_US
The Algorithm Behind Spell Checkers
zhlédnutí 402KPřed 4 měsíci
🖥️ GitHub: github.com/b001io/wagner-fischer ⭐ Join my Patreon: www.patreon.com/b001io 💬 Discord: discord.gg/jA8SShU8zJ 🐦 Follow me on Twitter: b001io 🔗 More links: linktr.ee/b001io
Are THESE Better Than Lists?? - The Josephus Permutation
zhlédnutí 62KPřed 6 měsíci
⭐ Join my Patreon: www.patreon.com/b001io 💬 Discord: discord.gg/jA8SShU8zJ 🐦 Follow me on Twitter: b001io 🔗 More links: linktr.ee/b001io Background Music: Mood by Alex-Productions | onsound.eu/ Music promoted by www.free-stock-music.com Creative Commons / Attribution 3.0 Unported License (CC BY 3.0) creativecommons.org/licenses/by/3.0/deed.en_US Slowly by Tokyo Music Walker | soundc...
THIS is Why List Comprehension is SO Efficient!
zhlédnutí 169KPřed 6 měsíci
⭐ Join my Patreon: www.patreon.com/b001io 💬 Discord: discord.gg/jA8SShU8zJ 🐦 Follow me on Twitter: b001io 🔗 More links: linktr.ee/b001io Background Music: Slowly by Tokyo Music Walker | soundcloud.com/user-356546060 Music promoted by www.free-stock-music.com Creative Commons / Attribution 3.0 Unported License (CC BY 3.0) creativecommons.org/licenses/by/3.0/deed.en_US
Avoiding My Mistakes!! - Shifting Zeros Problem
zhlédnutí 44KPřed 7 měsíci
⭐ Join my Patreon: www.patreon.com/b001io 💬 Discord: discord.gg/jA8SShU8zJ 🐦 Follow me on Twitter: b001io 🔗 More links: linktr.ee/b001io
The Even Groups Problem in Python
zhlédnutí 13KPřed 7 měsíci
⭐ Join my Patreon: www.patreon.com/b001io 💬 Discord: discord.gg/jA8SShU8zJ 🐦 Follow me on Twitter: b001io 🔗 More links: linktr.ee/b001io Background Music: Mood by Alex-Productions | onsound.eu/ Music promoted by www.free-stock-music.com Creative Commons / Attribution 3.0 Unported License (CC BY 3.0) creativecommons.org/licenses/by/3.0/deed.en_US
A Clever Way To Use Sets In Python
zhlédnutí 22KPřed 7 měsíci
💻 GitHub: github.com/b001io/python-challenges ⭐ Join my Patreon: www.patreon.com/b001io 💬 Discord: discord.gg/jA8SShU8zJ 🐦 Follow me on Twitter: b001io 🔗 More links: linktr.ee/b001io
Python Classes in 1 Minute!
zhlédnutí 159KPřed 7 měsíci
⭐ Join my Patreon: www.patreon.com/b001io 💬 Discord: discord.gg/jA8SShU8zJ 🐦 Follow me on Twitter: b001io 🔗 More links: linktr.ee/b001io
Why Are Sets Like This??
zhlédnutí 23KPřed 10 měsíci
Why Are Sets Like This??
*Args and **Kwargs in Python
zhlédnutí 249KPřed 10 měsíci
*Args and Kwargs in Python
List Comprehension in Python
zhlédnutí 51KPřed 10 měsíci
List Comprehension in Python
Python's Filter Function Explained..
zhlédnutí 30KPřed rokem
Python's Filter Function Explained..
Floats and Integers | How To Python
zhlédnutí 28KPřed rokem
Floats and Integers | How To Python
What Does Mutable And Immutable Mean??
zhlédnutí 18KPřed rokem
What Does Mutable And Immutable Mean??
What is Scope in Python??
zhlédnutí 45KPřed rokem
What is Scope in Python??
Python Yield Keyword??
zhlédnutí 123KPřed rokem
Python Yield Keyword??
Python Lambda Functions??
zhlédnutí 157KPřed rokem
Python Lambda Functions??
Python's Walrus Operator??
zhlédnutí 123KPřed rokem
Python's Walrus Operator??
Python Decorators in 1 Minute!
zhlédnutí 499KPřed rokem
Python Decorators in 1 Minute!
Recursion in Programming Explained..
zhlédnutí 16KPřed rokem
Recursion in Programming Explained..
How To Solve Google's Python Challenge!
zhlédnutí 46KPřed rokem
How To Solve Google's Python Challenge!
Why Is This Happening?! Floating Point Approximation
zhlédnutí 126KPřed rokem
Why Is This Happening?! Floating Point Approximation
How To Make An AFK Bot!
zhlédnutí 15KPřed rokem
How To Make An AFK Bot!
Python's Map Function Explained..
zhlédnutí 123KPřed rokem
Python's Map Function Explained..
How To Create Apps In Python Using Tkinter!
zhlédnutí 48KPřed rokem
How To Create Apps In Python Using Tkinter!
Add THIS To Your Python Scripts! if __name__ == "__main__"
zhlédnutí 163KPřed rokem
Add THIS To Your Python Scripts! if name " main "
The Python Math Module Explained..
zhlédnutí 12KPřed rokem
The Python Math Module Explained..
Using The Python Pickle Module
zhlédnutí 9KPřed rokem
Using The Python Pickle Module

Komentáře

  • @911Salvage
    @911Salvage Před 2 hodinami

    Dijkstra's algo is pretty easy to code. One of the very first assignments we got in data structures and algorithms course was to code Dijkstra's prime number algorithm in C or Java.

  • @hlubradio2318
    @hlubradio2318 Před 2 hodinami

    Oh lordy lord

  • @hlubradio2318
    @hlubradio2318 Před 2 hodinami

    Nice but noob programming which is a reason that i dont combined multiple conditions like that on my if statements

  • @givowo
    @givowo Před 3 hodinami

    ok but how slow is this really?

  • @AJBrickhead
    @AJBrickhead Před 3 hodinami

    How do I move a mouse when I rotate a rotation sensor

  • @DownloadableFox
    @DownloadableFox Před 4 hodinami

    If you are worrying about optimization, then you probably shouldn't be using Python.

  • @pedrocostalins8041
    @pedrocostalins8041 Před 4 hodinami

    print(link[4:]) ?????

  • @isrnick
    @isrnick Před 5 hodinami

    Just use a sieve like the sieve of Eratosthenes.

  • @SkotzGames
    @SkotzGames Před 7 hodinami

    If you're a coder, you won't make this mistake, if you're someone who copy and pastes code, you'll make this mistake.

  • @RealCadde
    @RealCadde Před 8 hodinami

    Documentation lists thousands upon thousands of specific functions that do various string operations. Regex does all of these things with a simple to learn syntax.

  • @SilverSuperGamer
    @SilverSuperGamer Před 8 hodinami

    Fun fact: a new scope is not created in a for loop

  • @sherwancaris5199
    @sherwancaris5199 Před 9 hodinami

    Without music, please.....

  • @soldiernumberx8921
    @soldiernumberx8921 Před 10 hodinami

    Cool but you could also solve this by first removing w then make one more line to remove dot but is not so elegant

  • @JohannVF
    @JohannVF Před 11 hodinami

    Noob question, but where is the value/argument for "num" being provided?

  • @dogslife4831
    @dogslife4831 Před 11 hodinami

    Very clever use of Mod Operation

  • @darkblood154
    @darkblood154 Před 14 hodinami

    Javascript ==> array Python ==> list

  • @lebuga
    @lebuga Před 14 hodinami

    I personally use replace("www.", "")

  • @adityaalmighty1
    @adityaalmighty1 Před 14 hodinami

    This was nice! Well done

  • @911Salvage
    @911Salvage Před 18 hodinami

    Yes, I've made a similar mistake. The way the documentation for str.lstrip() was worded didn't help me one bit. Thank goodness for Google Search and StackOverflow. However, I must note that str.removeprefix() did not exist until Python 3.9.

  • @CripsyFries
    @CripsyFries Před 23 hodinami

    Umm acutally str is a class 🤓

  • @potatofuryy
    @potatofuryy Před dnem

    A* My beloved

  • @nvs-different-ideas

    This is why I give value pointers in my own programming languages, like # - normal value, $ - system value, @ - runner/reader values Exp. dv str 7 echo str(8) echo #str

  • @matthewmcvicker824

    New reason to hate python: printing in the definition of a function

  • @RS-fz4ps
    @RS-fz4ps Před dnem

    Meanwhile, JavaScript be like, 6 + 9? Nice!

  • @duukvanleeuwen2293

    I'd use recursion

  • @michieleding1242
    @michieleding1242 Před dnem

    This is actually perfect for my game !!! Thanks lol

  • @PultsMoizer
    @PultsMoizer Před dnem

    Is it ok for performance to import the whole module and just use some of the functions in there? Or always better to import all 1 by 1

  • @fabian1551
    @fabian1551 Před dnem

    What font does this man use?

  • @yannisbaeyens
    @yannisbaeyens Před dnem

    We do: if user_input = '' . Is this also good?

  • @suvetar
    @suvetar Před dnem

    Good spot, that's a cheeky little impl. detail indeed! Jeff atwoood's Coding horror has a fun blog entry about obscentiy filters (20th Oct 2008). It's a fun observation if you like this stuff too!

  • @Gamedev-jm8el
    @Gamedev-jm8el Před dnem

    my version: def dup(removingdups): return sorted(set(removingdups)) old = ["a", "b", "a", "c", "b", "a"] new = dup(old) print(new) # dups stand for duplicates btw # sorted maintains order and set removes dups

  • @ceji566
    @ceji566 Před dnem

    cool. your solution on my old rig takes 31 seconds. your solution on my new rig takes 14 seconds. my solution on either runs in .. error.

  • @TheVergile
    @TheVergile Před dnem

    but isnt the point of using a global that it is NOT local? As in i could be updates between two loop iterations and we want the updated value. if i wanted to specifically use the global value as is when calling the function i wouldve entered it as an argument.

  • @RS-fz4ps
    @RS-fz4ps Před dnem

    Everyone is fighting about static or dynamic typing in C/Python, but a beginner can’t make a mistake like this when you can’t use a string where a Boolean goes.

  • @Chill018
    @Chill018 Před dnem

    but how would you use it in hundreds of function in different py files? would you import it from a separate file or define it in every one of those scripts with functions?

  • @nikdiklic
    @nikdiklic Před dnem

    Python devs just discovered short circuiting

  • @water1374
    @water1374 Před dnem

    I think this guy did the videos for my Pearson textbook.

  • @amiganer681130
    @amiganer681130 Před dnem

    Even a old C64 had that called "Def". You showed a unnamed lambda, so it can not be reused. You can say "A=lambda..." the A is more like a function. Sometimes you need to use function, so you can put it in a lambda.

  • @redtomato258
    @redtomato258 Před dnem

    Thanks a lot!

  • @passportbro904
    @passportbro904 Před dnem

    me getting syked to study all day so i master decorators, me after 1 minute, im running out of weed

  • @passportbro904
    @passportbro904 Před dnem

    like neo in the matrix learning kung fu in 5 seconds, buzzzzeeeezzzzee (after 1 minute) I know Decorators

  • @dubbynelson
    @dubbynelson Před 2 dny

    python, where there's a function for everything and you learn nothing

  • @realitant
    @realitant Před 2 dny

    I wouldn't really consider this complete without an invalid selection resulting in a repro pt. Typos shouldn't cause a crash

  • @joemama-bo5ef
    @joemama-bo5ef Před 2 dny

    slicing? for link in links: print(link[4:])

  • @jambalaya974
    @jambalaya974 Před 2 dny

    How the fuck do I have over 5 years in python and I've never used the unpacking operator? What the fuck?

  • @robinsonrojaslopez5200

    I don't know much about how the algorithm works, but if you are looking for the smallest value, I understand that it cannot be less than zero since this way you would avoid the problem of entering a cycle in which the value is decreased. infinitely, to prevent the value from being less than zero you can look at what the weights are and look for the smallest one, in the first example -30, and add the absolute weight in the rest in this way this node (and the others with existing negative values) has a value equal to or greater than zero and the problem is avoided.

  • @simonebranca1972
    @simonebranca1972 Před 2 dny

    what could possibly go wrong? 🤔

  • @duukvanleeuwen2293
    @duukvanleeuwen2293 Před 2 dny

    OMG I literally stumbled across this problem today!!

  • @happyraider815
    @happyraider815 Před 2 dny

    this is what i was searching for many years ago. i am too stupid before to even know what question i should be asking. i cant find it anywhere so i just quit learning python. and now here is the answer out of nowhere. maybe this is a sign

  • @amiganer681130
    @amiganer681130 Před 2 dny

    Here it is everytime "www.", that are 4 chars, so use link[4:].