mom can we have emacs no we have emacs at home emacs at home: 42:05
@kernelk19313 жыл бұрын
looks like you've uploaded a brand new quality content, tsoding!!
@larryd95772 жыл бұрын
Instead of maintaining a bool in every node: A memory-efficient solution (for reasonably large trees) for marking the end would be to use a guard-noded (one should be enough) which is inserted as a leaf of every end of a word.
@dingalong143 жыл бұрын
Haven't watched in a couple of weeks, glad to see you've switched to the *objectively superior* text editor. Jokes aside, nice stream. I always pick up at least one or two little things I didn't know about previously.
@Nick-lx4fo2 жыл бұрын
Gedit, you mean, is the objectively superior text editor
@experiment00033 жыл бұрын
So, this guy could work for any company he wants (Google, Tesla, Amazon, etc) and be a senior engineer at the least! instead, he chooses to make his living via streaming.
@Chaosman883 жыл бұрын
If I could just code 4 times slower than him, I would be a respected member of my team
@venkateshgunda253 жыл бұрын
It could be because at a large company, coding only comprises about 40 to 50 per cent of the time. Rest is projects, meetings, presentations and other corporate BS that eats up valuable time.
@richienguyen27033 жыл бұрын
not every software engineer wants to work for big tech companies. They're all big so their development process is more bureaucratic, and some people just purely love coding.
@AndrewTSq2 жыл бұрын
agile ruins the fun of coding.
@BboyKeny Жыл бұрын
@@dill__pickles Well you are a God on earth. So all other people, aside from you, fit your description.
@bart2019 Жыл бұрын
2k per node is not a lot for modern computers, but at 1024 nodes per tree that is 2MB, and that is a lot for modern CPU caches. On its own you won't notice it, but on a heavily loaded computer you might notice it because 2MB is easily a quarter of the entire CPU cache. In this case, a theoretically much slower approach but with a much much compact storage, for example with a simple comparison loop in a linked list, would put much less strain on the cache.
@arroba32183 жыл бұрын
THIS is what programming looks like. I'm into web development, I don't feel a programmer at all
@JustSomeAussie13 жыл бұрын
Because you're not :)
@lonelyfloat25822 жыл бұрын
Just do what you enjoy doing, doing anything else (unless it's for a job or something similar obviously) is stupid IMO
@Leonhart_938 ай бұрын
Not sure what people work on in web dev to say that they don't do stuff like this. Writing elegant programs that do a specific task efficiently should be the target in anything you use. If I write a 1000 line JS program for a specific page to have some arcane functionality, then it's clear that I need to apply a lot of programming paradigms to do it well.
@Rohan-bg8ci3 жыл бұрын
"That is much productive than Java enterprise edition developer" -chad Tsoding
@N00byEdge Жыл бұрын
Another way to indicate the end of a word is to set index 0 of the children array to something, just like you would have a null terminator in a c-style string
@geovanniportilla71592 жыл бұрын
Pure data structure, algorithm, and design. This is pure gold. I follow your content and here is an idea: maybe, would be nice to have a project that created a programming language for database management. I don't know something basic: relational algebra, join, or some k-tree search algorithms. May be is something you are not working in the past and it's challenging for you. Peace!!
@lieryan91373 жыл бұрын
For the use case of autocomplete, especially one that needs to work on Unicode, I think a regular binary search tree would work better than a trie. For finding candidate completions, you'll want a binary tree search implementation that returns all nodes in a range. For example, if you want to find all words that has a prefix of "sal", you'll want a search function that returns all nodes whose values matches `"sal"
@edusandalo3 жыл бұрын
How would this approach work with Unicode? Would the search be `"...A"
@keldwikchaldain9545 Жыл бұрын
To compress memory the primary way would be to use an array mapped trie, which trades memory footprint for increased memory allocations, but with pooling that can be reduced as well.
@Teacher_Ali3 жыл бұрын
One of the coolest channels on internet world.
@geovanniportilla71592 жыл бұрын
This dude is just insane!!! Pure data estructure, algorithm and design. This is pure gold.
@DJohn0013 жыл бұрын
Hello, what's the reason that you're not binding your local branch with your remote one? for example: `git push -u origin ` then you did have to type your branch each time you commit. Instead you can just use `git push`
@froggoboom2 жыл бұрын
the man types fast
@bigbluebiosphere2 жыл бұрын
commit-ee commit-ee pushy-ee pushy-ee made me LMAO. But nowhere near as much as cucumbersome did.
@bonchonmaru Жыл бұрын
1:47:12 is it possible to prevent stackoverflow in `print_autocomplete` for deep trees?
@TsodingDaily Жыл бұрын
You probably can by using a bigger stack. Which might mean increasing the size of the callstack itself or implementing a non-recursive solution that maintains its own stack. In the later case you can have whatever size of the stack you want.
@lishugupta3 жыл бұрын
U earned a sub just by the title of video🔥🔥
@petsesto3 жыл бұрын
34:17 children[69] ... Tsodin nooooo🤣
@miniflint2423 Жыл бұрын
How could I achieve something like this guy do. He’s so good
@archavez1003 жыл бұрын
How did you zoom and add that spotlight to your cursor? At 11:08
@iuc72542 жыл бұрын
He wrote an application in nim to help him do that.... you can find it on one of his github repos under the name of Boomer
@MaxHeroGamer2 жыл бұрын
The go thing made me thing why Erlang is so brilliant.
@arkamel59873 жыл бұрын
you can mark the end of the word not with bool flag, but instead put empty node at \0 in children
@derekburlingame2133 жыл бұрын
That doesn't work for cases where words like "dog" and "dogged" are both in the structure, since the first 'g' would have children, but also be the end of a word.
@DylanNelsonSA3 жыл бұрын
@@derekburlingame213 They meant adding a node at index 0, not having 0 children. So it would be like treating the word as a c-style string with a null terminator.
@coffee-is-power3 жыл бұрын
you dont need to create the project, when you push to an repository that doesnt exist and you have permission to create repositories, it creates automatically
@baka_geddy2 жыл бұрын
How so? Can you share it?
@lolcat699 ай бұрын
It would be interesting to use this data structure for AI, imagine like passing binary files to this and passing ut to an AI, it could figure out a file is X type based on the signature or smth and ut would learn to clasify files or smth like that
@ItzAnameOk2 жыл бұрын
Amazing
@tobeypeters3 жыл бұрын
Did you say, There’s no Switch...case in c?, around 1:18:00 ? Idk ... Anyhow would love to see how to do this in python.
@TsodingDaily3 жыл бұрын
No, I didn't say that there is no switch-case in c. Please listen to what I've said again. You missed two important words.
@ricoh513 жыл бұрын
No switch for string 😉
@anon_y_mousse2 жыл бұрын
@@TsodingDaily Fun fact, AMD's optimization manual had an example of how to simulate string switching by hashing constants ahead of time. With C++'s constexpr you could have base that allowed adding words with minimal effort. (Hopefully you'll be back and posting in the near future.)
@ratherbyexploring48982 жыл бұрын
Missed opportunity to call this repo "Tsrie"
@tentative_flora26903 жыл бұрын
I hadn't thought before about someone using recursion in an intuitive solution before. This was really cool.
@yramagicman6753 жыл бұрын
Once you start working with recursion it becomes more and more intuitive. There are a number of problems that are actually easier to solve with recursion than they are with iteration. Zipping 2 arrays is one example of this that I used recently. I implemented the recursive algorithm for it in less time than it would have taken to figure out how to do it iteratively.
@tentative_flora26903 жыл бұрын
@@yramagicman675 I guess I am so used to trying to stuff things into while loops I miss out on a lot of good use cases.
@yramagicman6753 жыл бұрын
@@tentative_flora2690 get out of your comfort zone and try a language that forces you to use recursion. Lisps are an easy way to do that, and the easiest one of those to get started with is probably Racket. I really enjoy Racket. It has taken Pythons place as my go to language for basic scripting.
@yukwa86723 жыл бұрын
🔥🔥
@hrisheekeshdandekar51262 жыл бұрын
What is the theme this guy is using???
@L1Q2 жыл бұрын
29:03 cope
@hindenburg30383 жыл бұрын
Where I can get the link to his discord server?
@csbnikhil3 жыл бұрын
Twitch About Page
@trungthanhbp3 жыл бұрын
this guy is funny, haha
@s000x Жыл бұрын
Ur emacs config got me to patch my neovim so current line number is aligned with relnum lol
@alexzander__63343 жыл бұрын
you just moved to vim from emacs?
@zahir.parker4 ай бұрын
Which font is this ?
@trejohnson76773 жыл бұрын
We have the same brain but not the same muscle memory or gut.
@rogo73303 жыл бұрын
Not watched the whole video yet, but what i think is storing pointers to every character is kinda pointless. What we are really care about is branches. That saying we really wanna store pointers to each individual string (null-terminated, btw, that way we not gonna waste 2kibi on each character lol) and then just cat them together. Btw, we can do the same trick with null termination with our pointers! LMAO А потом всё превратится в ад из незнания сколько на самом деле памяти занимает наша программа, кек
@anon_y_mousse2 жыл бұрын
Exactly, and then the index into the string and a length. That said, I really wish people would stop using those ldlotic prefixes. Other than storage device manufacturers who rip people off, no one ever meant kilobyte as 1000 bytes. I will never use those prefixes and just keep saying kilobyte and meaning 1024.
@miezekatze35363 жыл бұрын
Where is Emacs?
@tokiomutex41483 жыл бұрын
error: Where: command not found
@sahilbaori90523 жыл бұрын
@@tokiomutex4148 Lame.
@tokiomutex41483 жыл бұрын
@@sahilbaori9052 error: Lame.: command not found.
@هلالمجيد-ظ3ك2 жыл бұрын
What kind of linux does he use?
@narigoncs2 жыл бұрын
Debian
@johndowson18523 жыл бұрын
1:08 CAN YOUR GITHUB DO THIS?
@kuwapt9513 жыл бұрын
Hello hello
@dream11tatyabichoo927 ай бұрын
how to donate from India
@MoeQ_3 жыл бұрын
discord link please ?
@Q_203 жыл бұрын
proud to be a reckless java code duplicator
@tokiomutex41483 жыл бұрын
So you're using Vim now
@dibyojyotibhattacherjee42793 жыл бұрын
Why no cpp?
@latingm3 жыл бұрын
why cpp
@dibyojyotibhattacherjee42793 жыл бұрын
@@latingm cuz, it's an awesome language.
@avananana3 жыл бұрын
@@dibyojyotibhattacherjee4279 brainfuck is an awesome language as well
@dibyojyotibhattacherjee42793 жыл бұрын
@@avananana Haven't used it before, gonna check it today, thanks for the suggestion 🙂
@dibyojyotibhattacherjee42793 жыл бұрын
@@SimGunther ohh, yea, Tsoding's subscribers are really nice people.