Hey everybody welcome back to the channel today. We're gonna take a look at a terminal emulator named kitty now if You've watched the channel before you know that my preferred terminal emulator is termite and it has been for a long time and after playing around with kitty I'm pretty sure I'm gonna be sticking with termite. So that's just kind of a spoiler for you, but Kitty does have some interesting features and it has a very Interesting I'll say configuration file. So we're gonna jump into that here in just a second But before we do make sure you hit the subscribe button because we do Looney Tunes Videos seven days a week on all sorts of false related topics Terminal emulators window managers desktop environments. We talk about it all on this channel or more specifically I do we also do a podcast one So we called the Linux cast which is where the channel gets its name from so make sure you hit the subscribe button and the notification Bell icon so you don't miss anything. So that being said, let's jump into the documentation for kitty so It is very well documented for a terminal emulator, but I haven't seen too many out there that are this well documented actually Termite I don't think really is But I'll be honest. I haven't looked at the termite Documentation in quite some time. I know it's just on github That really doesn't mean all that much I Think all acuity does have some a documentation like this, but kitty is very well documented. It's um It's meant to be a very fast terminal emulator kind of like Alacrity, I think it's like GPU enabled or whatever I'm like Like assisted I guess so if you're looking for a fast terminal emulator kitty might be the one that you're doing So let's actually take a look at it now.  That's all you'll get I Did not want to do that. I've also changed the font and increase the font size So those are the four things that I've done. I've changed the color scheme I've went through and changed the font and the font size But we'll we'll take a look at it. So let's uh by default The configuration file is in dot-config kitty If we do an LS all is there is the comp file So if we them into kitty dot-con and this is what you get by default it is um When I first seen this I was like what the hell is that? Yeah, I had never seen nested or whatever Configuration files like this before I in them. I'd never seen it before. I was like, how am I supposed to work with that? Haha, it was very confused. It was a very confusing five minutes for me Like I don't understand how am I supposed to go there if you go on these and just hit enter enter Just takes you down and down line. So how do you do get to that? So the way you do it is actually just going to insert mode. That's how you do it But you got to remember now you're in insert mode. So um I wonder if there's there's probably another key binding in vim to open those up without going in in insert mode. I wonder Because if you if you oops I don't I don't remember how to close it now This is I'm telling I've never seen this before it was very confusing anyway So this is um by default everything is commented out. So you have to go through And uncomment things out and I actually believe that I think I have to go through and actually Remove that column too Yeah, we'll see if that actually works. I'm wondering if uh, that's the reason why I didn't show a new new fetch earlier Anyway, so these are the fonts. There's a lot of stuff you can do here with fonts um More than is I think not completely necessary I wouldn't go so far as to say I am a suckless kind of guy I've made videos before saying that suckless is kind of terrible unless you add some stuff to it So I want my terminal emulator and window manager for that matter to have features But I don't want to have too many features, you know, because It goes past being convenient to have some features to being What luke smith would say would be bloat Of course, I don't think he actually uses the word bloat anymore because I think it became meme worthy. So whatever But This looks I mean granted. This is just the documentation. You could remove all this stuff If you didn't want to because most of this here these paragraphs and paragraphs of texts are just explaining what the things do so um This is all just for fonts and I mean that is uh That is over 100 and 100 Almost 150 lines of font stuff. So and then we have cursor customization scroll back, which is 46 lines where Scroll back does not need 46 lines. It needs two. So let's actually see take a look and see what the hell they're doing here Literally scroll back lines. That's the only one you need That tells you how many lines you can scroll back in your history and your terminal You only need that one. What is the rest of this stuff? Scroll back pager, uh, I don't know that is um number of lines All right, here's another thing that you'll notice. I'm sorry another thing you'll notice about the configuration file is that Unlike normal things the uh normal configuration files the kind of explaining whatever It is explaining comes after the thing that it's explaining So we have we have the command and then we have the the explanation of the command command exclamation explanation of the command That is just Very weird. That's not that's not the way I would do things I guess but you know whatever So this tells you how many lines you I guess just modify the amount of scrolled by the mouse lines Modify the amount scrolled by the mouse wheel if you're gonna have uh, you know Grammar is important Touch scroll rule, I'm assuming this is for the touch pads. I mean that's cool I so really that's not 48 lines where the stuff that's that's one two three four lines of stuff with 40 lines worth of explanation explanation One of those words that I just cannot say worth a damn today explanation so Okay, I mean, that's not I mean, it's not a line. It's just really weird Same thing with the mouse thing here. There's 104 lines. That is going to be almost definitely Mostly explanation Um, you know most explanation that's really like six lines Focus follows mouse, which is That's a weird setting to have in a terminal emulator. I'm just saying that's something for your window manager. Why does it need this? Um, so let's see we're here. We have um terminal Bell I'm assuming that's for what sound? Yeah Okay, window layout tab bar. So kitty has tabs in it by default, which is I don't know I don't really need tabs. It's really weird Um I like tabs and other things like file managers and stuff, but I don't really need tabs in my in my Uh terminal emulator I also don't need multiple windows because I use a window or you like a split window like you'd have in like tmux or something I use a window manager for a reason I guess I'm just simple that way Advanced here's the color scheme So basically the color scheme is fairly, yeah easy to get around it's just uh most of this stuff here is dealing with opacity although Oddly the opacity settings are in two different places. So there's the dynamic background opacity here I think this has to do more with if you're going to use a background image, which you can do for some Inexplicable reason. I'm not sure why you'd want to use a background image In your terminal emulator, but whatever But there's also above this. There's a place where you can set just regular opacity I mean It just seems unnecessary right to me I don't know if anybody who wants a terminal emulator. It has a background image Solid colors are the way to go other than that. This is just a standard Uh Color scheme that you can get from something like terminal dot sexy or something What I did was I went through and found a term a color scheme And then just copy the termite one the termite one is Uses syntax almost exactly like this. You just have to go through and remove the equals signs in between So that's really all I did there um So and then the last one I want to look at is keyboard shortcuts So this does have some keyboard shortcuts I don't usually use keyboard shortcuts in my terminal emulator But it's nice to know that you can get into like vim mode or yes, um Or create key bindings to go up lines and repeat Uh commands or something. I don't know There's just there's a ton of them here or quite a few of here anyways, so I don't there's more. I didn't even notice that there's more What's the difference between scroll back and scroll on? Oh, this is actually within in Okay, so this is nested within the uh the key binding section I didn't even know you could do that in vim. Okay, so you went on That's the configuration file. So overall my thoughts on that are it's very very complicated. It's very very long It's over 1,300 lines long. I bet you you could probably take about 1,000 lines away by not having the documentation built right into the configuration file I mean, that's a preference. I guess I would rather just use a man page Say if you knew you need to do this just use a man page But maybe I'm just old-fashioned like that. So the last thing I want to do Is look at the time See if we can definitively say this is faster than something like termite. So let's uh cd into our home directory and clear you know command l I've always forget that Control l will actually go through and clear things. I always forget that key binding. So I just use c I have an alias for c That does clear Anyway, so let's do time neo fetch and fish goes through and You know So these are these are the numbers we're looking at here the beginning It was like 76 milliseconds or so And let's look at termite termite is the one that I use neo fetch. Oops time neo fetch Look at that. Look at that Almost exactly the same uh Termite a little bit faster. Also not gpu accelerated on termite. So you don't have to deal with any of that and just For comparison, this is this is still termite Let's cd into that config termite ls and vim config This is the config file for termite It is 87 lines long Uh, and some of these are actually fonts. So these could actually all go away Okay That's in comparison now there's Obviously more you can do with kitty because termite doesn't have built-in key bindings as far as I know Uh I've never actually looked I don't need them. Um, let's go back to kitty kitty oops I actually have to spell things right Let's zoom in here. Let's do time Uh, I don't know Well, let's just do time ls And that runs in 10 milliseconds and we'll do time ls Like ran as like 134 Interesting. So at least with this, um Command it was much slower But these are reading as micros in that milliseconds I don't know Which one's smaller micro section? I I'm assuming micro section says smaller than a millisecond But I might be completely wrong have that completely backwards. I don't know. Um Fish is weird because you let's run it again 153 micros 96 micros so that's less um Termite is faster. I'm just going to go on and say that these are just regular small ass Commands that she don't don't take really any time at all but Termite is faster so That was the first look at kitty My impressions I've only played around with it for a little bit before I started recording and whatever you've seen on this recording Um, my impressions are it's meh Why would you use it? Uh, unless you need a lot of configure unless you need a lot of options for your terminal emulator That would be a an option But I think a lackity is a little bit better You put together from what I've you know the little bit of lackity that I've used And it's probably about as fast. So termite isn't or uh, kitty is not slow Termite is still faster. Termite is just faster people and I don't understand. So like the likes of dick distro tube and um Brody robinson they all use a lackity and preach it to high heaven because it's the fastest terminal emulator ever termites faster And at least unless I'm reading that completely wrong like which I could be I suppose It's happened before I've been wrong many times before so on that happy note Thanks for watching if you want to subscribe Support the channel you can subscribe hit the notification icon You can also support us on patreon at patreon.com slash linux cast again. Thanks for watching. I'll see you next time


In a series of videos I did about saturated fat, I talked about a major campaign launched by the global dairy industry to neutralize the negative image of milk fat among regulators and health professionals as related to heart disease. That campaign continues to this day, with a publication of a meta-analysis demonstrating neutral, meaning non-harmful associations between dairy products and cardiovascular disease and death. OK, well, first of all, how do we know the dairy industry had anything to do with this study? Well, it was published in a journal that forces authors to disclose financial conflicts of interest. Let's see what they divulged. Dairy, dairy, dairy, dairy, dairy, dairy, the fourth largest dairy company in the world, dairy, dairy, milk, beer, soda, McDonald's, dairy, dairy, dairy, dairy. Oh, and the study itself was explicitly funded by dairy, dairy, dairy. OK, then. The other big new one was this, suggesting that a little bit of cheese every day isn't just neutral, but actually good for you. And they make it clear that they have no conflicts of interest. They're just employees of the Yili Innovation Center and the Yili R&D Center. You know, China's largest dairy producer, making it one of the world's largest dairy companies? OK, but how can cheese consumption be associated with better health outcomes? Well, most of these studies were from Europe, where cheese consumption is associated with a higher socioeconomic status. See, in Europe they're not eating cheese whiz and velvita. Cheese is generally an expensive product, and so who eats cheese? Those with higher paying jobs, higher socioeconomic strata, higher education levels, all of which are associated with better health outcomes, which may have nothing to do with their cheese consumption. Higher socioeconomic groups also consume more fruits and vegetables, and more candies. So I bet you could do a population study and show candy consumption is associated with better health. Shh, don't tell the National Confectioners Association. Too late, did you know that candy consumers have lower levels of inflammation? A 14% decreased risk of elevated blood pressure brought to you by the candy industry and the USDA, our government which props up the sugar industry to the tune of a billion dollars a year. It's like when our tax dollars are used to buy up surplus cheese. Paul Shapiro wrote a great editorial. Imagine the headline, government buys 20 million in surplus Pepsi, or hard-earned tax dollars buying up millions of unwanted cola cans, all as a favor to the flailing soda industry, which just kept producing drinks no one wanted. As outrageous as such a government handout to the soda industry would be, that's exactly what the USDA is doing for the dairy industry. Michelle Simon did a great report on how her government colludes with the industry to promote dairy junk foods. The federal government administers check-off programs to promote milk and dairy. McDonald's, a six-dedicated dairy check-off program, employs at its corporate headquarters to try to squeeze in more cheese. That's how we got double-stake quesadillas. That's how we got three cheese stuffed crust pizza complete with a summer of cheese. These funds are being used to promote foods that contribute to the very diseases our federal government is allegedly trying to prevent. Does it make sense to tell Americans to avoid foods high in salt, sugar, and saturated fat while engaging in the promotion of those same foods? Look, the meat and dairy industries can do what they like with their own money, but the public power of taxation should be used for the public good, not to support the dairy and candy industries.


The origin of the bill of war project was the shooting at Parkland He used an AR-15 rifle that he purchased legally to gun down his former classmates That provided the catalyst to finally weigh in as a collective on this gun debate specifically relating to the reform and the collusion between our government and the NRA Don't worry about the NRA. They're on our side. You guys here for you are so afraid of the NRA There's nothing to be afraid of 17 people had to lose their lives the end of a barrel of an assault rifle Our government and the NRA are pretty steadfast in keeping those weapons of available to the general public including people under the age of 21 and There's just not a whole lot of movement and action in regards to fixing this issue The billboard originally said shoot a 50 caliber for $29 we changed it to shoot a school kid and Then added a subtext a smaller sticker in the corner that read defend lives reform laws Many in legacy media love mass shootings You guys love it Now I'm not saying that you love the tragedy, but I am saying that you love the ratings Crying white mothers are ratings gold And of course there's a metaphor to be spoken about them in the $29 which was our way of saying it's the government The NRA really are valuing gun ownership and second amendment rights of our citizens over that of human life


Welcome to the lecture on syntax analysis part 6. So, today we will continue with bottom up parsing study what are SLR1 grammars, LR1 grammars, etcetera, etcetera. To do a bit of recap, so we discussed the concept of viable prefixes, items, valid items and then we also discussed the procedure for building the LR0 automaton. Here is the example I showed you last time and the method of construction is very simple you know the to begin with the item s prime to dot s is the only one which we are going to have and then we take the closure on it. So, that gives you an initial set of items and now we continuously apply the go to function and go on including as many sets of items as possible into the collection c and when we cannot add any more items we stop. So, each set in the above collection is a state of the LR0 DFA and this DFA recognizes viable prefixes. So, each state of the DFA contains only items which are valid for a particular viable prefix or a set of viable prefixes. So, let me explain how exactly LR0 parsing happens with respect to this particular DFA. So, let us consider the simple string id which is derived from this grammar. So, we start with s going to e hash apply this production and then we apply the production e going to t and finally, we apply the production t going to id. So, we get the string id hash. So, let us see how it is parsed using this LR0 automaton. So, as usual we begin with state 0 which is the initial state and then on the input id we go to state number 3. So, remember state 0 is on the stack now id is pushed on to the stack when we see it and it takes you to state 3 which is again pushed on to the stack. So, in state 3 it says it is a reduced state. So, and the reduction is by the production t going to id. So, the implication of this would be to pop the top symbol of the stack and since the state is also included we pop two symbols of the stack and that actually exposes the state 0 on the stack. Now, the non terminal on the left hand side is t. So, we apply the go to function on state 0 and that takes us to state number 2. So, now we have pushed the non terminal t on to the stack and the state number 2 also on to the stack. Now, it says again reduced by e to t. So, we pop state 2 and the non terminal t from the stack again we get state 0 as the top of stack and now since the non terminal on the left hand side is e we apply the go to function on state 0 and the non terminal e which takes us to the state number 1. Now, the next input symbol is hash because this is a shift state it is not a reduced state and on hash it goes to state 5 where a reduction by s going to e hash is actually indicated. So, we again pop items from the stack and this state 0 and we push the non terminal s on to the stack and that is an acceptance. So, this is how the terminal string id is parsed. So, let us consider a slightly more complicated terminal string id plus id. So, id plus id hash is derived from this grammar using s going to e hash then e going to e plus t this t will go to id this e will go to t and then go to id. So, that is how id plus id would be hash would be derived again we start from 0 go to state 3 which indicates a reduction go back and on t we go to state 2 which again indicates a reduction. So, go back to state 0 pop symbols and then go to state 1 on e. So, now the plus will take us to state 6 and id will take us to state 3 again there is a reduction. So, remember that 3 and 6 are on the stack. So, we pop these two id and sorry id and 3 are pop from the stack to expose the non terminal 6 and 6 on the non terminal t takes us to state 8. So, here we now have on the stack e plus e 0 e 1 plus 6 t and 8 which indicates a reduction by e to e plus t. So, we go all the way back to state 0 and on e we again go back to state 1. So, and then hash makes it go to state 5 and we accept the string. So, this is how parsing happens using this automaton of course, all this is made easier once we actually have the table itself. So, here is the table. So, before going to this table I must explain how exactly the table is filled. So, shift and reduce actions in the state are filled as we now discussed. If a state contains an item of the form a going to alpha dot that is called a reduce item then a reduction by the production a to alpha is the action in that state. If there are no reduce items in a state then it is a shift state and shift is the appropriate action. There could be shift reduce conflicts or reduce reduce conflicts. So, when thus that happen there is a shift item and there is also a reduce item in the same state or there is more than one reduce item in the same state. So, it is you know it is normal to have more than one shift item in a state. So, there is no question of having a shift shift conflict at all. So, if there are no shift reduce or reduce reduce conflicts in any state of this DFA then the grammar is said to be L R 0 otherwise it is not L R 0. So, this is the you know table for the set of items that we have already constructed. So, let me show you the procedure for filling it. So, we actually look at the items. So, we have state 0 we assume that we have not filled anything here. So, the whole table is empty. So, in the we have state 0 and let us see on which items indicate shift on a terminal symbol because the non terminals after the dot really indicate a go to. So, only the terminal symbols after the dot indicate a shift on to the stack. So, there is a parenthesis and there is a I D as well. So, on state 0 for the left parenthesis there is a shift and for the I D there is another shift. So, when we advance the dot after the left parenthesis you know. So, the state that we get into would be you know. So, this is a state number 4. So, here it is right. So, parenthesis dot E and then the other one on I D you know 0 on I D goes to the state T going to I D dot. So, that is state number 3. So, now the go to part can also be filled for this particular state. So, there is a non terminal E after the dot in these items and there is a non terminal T after the dot in this particular item and the other two we have already considered. So, on the non terminal E it goes to a state which contains the item E going to E plus dot T and that would be state number 1. So, this is you know on. So, E dot hash and then E dot plus T and then E dot minus T. So, of course, S going to dot E hash is also an item with E on the right hand side and after the dot. So, all these three items actually are in state 1. So, that we have a go to of 0 on the non terminal E as state number 1. So, and similarly 0 go to of 0 on non terminal T is state number 2 that is this particular thing you know. So, E going to dot T will yield us the item E going to T dot. So, this is the manner in which we are going to fill all the entries in this particular table. So, now again if you consider the same string I D hash and with the help of these this table and the set of items. Let us just again make sure that we understand how it is parsed. So, we start from state 0 and on I D it says shift and go to state 3. So, that is the state number 3 here and we see that it is a reduce item that is the reason why this state indicates you know this state indicates a reduction by the production T going to I D. And then you know. So, that means we must pop the stack. So, I D is removed state 3 is removed and we get state 0 again on the stack. So, the non terminal T from state 0 takes us to state number 2. So, that is here. So, we would have pushed the non terminal T and the state number 2 on to the stack. So, we have gone to state number 2 here and it has only a reduce item. So, there is a reduction by E 2 T which brings us back to state 0 and state 0 on E it takes us to state 1 that is this particular state and state 1 contains you know S going to E dot hash E going to E dot plus T and E going to E dot minus T. And then we read hash we go to state number 5. So, that this is state number 5 and which is an accept state. So, in state number 5 the entire row says accept on any symbol. So, that is how the string is parsed. So, and you can also see that there is exactly one entry in every one of these you know slots right. Here of course, accept is nothing but a comment you know. So, reduction by 1 and the it says it is an accept state. So, it is not that there are 2 entries of a reduce or you know nature or something like that. So, this is a grammar which is definitely L R 0 because there are no conflicts in any state. So, let us go further take another example of how the L R 0 automaton is constructed. So, this is the grammar and this is the automaton that we will study how to construct it as well. So, we start from state 0. So, this is the augmented grammar S prime going to dot S S going to sorry S going S S prime going to S S prime going S going to A A S and S going to C. And the initial item we begin with is always S prime going to dot S. So, applying the closure we add these 2 items S going to dot A S and dot S going to dot C. There are no more items to be added. So, once state 0 is constructed we you know construct the go to state for this particular item S prime going to dot S becomes S prime going to S dot no more items can be added here that gives us state 1. So, when we advance the dot after the A here. So, we get A dot A S. So, that gives us this item and now the closure includes all these items you know starting with A and then there is a item with S after the dot. So, the S items are also again added. So, remember there are 2 S items here S going to A dot A S and S going to dot A S, but the dots in are different positions. So, there is nothing incorrect about this. So, now S going to C dot gives us state 3. So, we have covered all the items in state 0 this does not give us any more. So, here it gives us S going to A A dot S and then we add these 2 items by the closure operation and then this gives us A going to B dot A. So, that is this state and then A going to S dot P that would be this state with this closure items with these closure items and S going to A dot A S is the same state number 2 and S going to C dot is already covered it is state number 3. So, this gives us S going to A A S dot that is state number 5 and this item gives us S going to A dot A S which is already state number 2. So, no new states are added here and this of course, S going to dot C again gives us nothing more extra. So, this state again does not give us any extra states B dot A going to B dot A gives us A going to B A dot again this is a reduced state and nothing more can be added to this. So, this of course, gives us some more it gives us a state A going to S B dot and B going to B dot A is state number 10 with extra closure items here and this and this do not give us any extra states B going to S dot is a state which is state number 12. So, this B A dot B going to B dot A gives us B going to B A dot and the others do not generate any more new states. So, you can see that this particular grammar does not have any shift reduce or reduce reduce conflicts in any state there is exactly one reduce item in a state whenever there is one. So, and there is not any shift item as well. So, this is a grammar which is L R 0 here is the you know table for it and here is the table the sets of items the grammar and the D F A all put together. So, let us just take one state and understand again how to fill the table. So, state number 2. So, here from state number 2 on B. So, we go to state number 6 right. So, B dot A. So, state number 6 is here B dot A. So, state number 2 on B says shift 6 right and then there is a C here. So, on C it should go to state number 3. So, 2 on C says go to state number 3 and on A of course, this remains you know dot A S this is S going to dot A A S. So, this generates a state which is state number 2 itself. So, it remains in state number 2 and the operation is shift. So, you can see the self directed arc here right regarding the go to part of the table. So, 2 on S you know. So, 2 on S goes to state number 8. So, the reason being there is a symbol S after the dot A going to dot S B. So, this goes to the state containing A going to S dot B. So, A going to S dot B is here right state number 8 and on non-terminal 8 goes to state number 4. So, that is because we have S going to A dot A S. So, this gives us state number 4 which contains A A dot S. So, this is the way in which we fill up the entire table and since there is exactly one entry in each of the slots this grammar is indeed L R 0. So far we saw examples where the grammar is L R 0. So, it is time to move on and find out you know whether there are grammars which are not L R 0 at all they violate the L R 0 property indeed. So, we take the old grammar with plus and minus, but remember the old grammar had S going to E hash. We have really removed the hash. So, now it is time to explain why we removed it and what happens if we remove it. So, let us construct the set of items for this. I am not going to explain it in great detail again, but we have this first item and then the closure. Then the items S going to dot E S going to dot E plus T and E going to dot E minus T they give is to state number 1 which contains S going to E dot E going to E dot plus T and E going to E dot minus T. So, it is easy to see that there is one reduced item and there are two shift items. So, this is the reduced item and these two are the shift items. So, there is a shift reduce conflict in this particular state. So, once we reach this particular state on a particular input symbol, you know we are not able to say whether the state should reduce by the production S going to E or shift the next item on to the stack. Remember the table when we actually operate using the table the parser does not see what exactly is the item and then decide the action you know it is there is exactly one action in each of the slots. So, on 2 on a becomes S 2 etcetera. So, whereas, for the reduce there we always had exactly one item R 4 and this was S 7. So, in the entire row we always said it is a reduce by 4 see for state number 5 it is always a reduce by production number 2 and for state number 3 it is always a reduce by production number 3 and so on. So, in other words for the shift item you know we see what exactly is the symbol and push it on to the stack, but for the reduce item we should be able to say that it is a reduction by a particular production without even bothering about the next input symbol. So, this is the drawback of the L R 0 parsing strategy because we do not consider the you know what exactly is the next input symbol in order to say whether it is a reduction or it is a shift. So, in this case the grammar fails the L R 0 test, but this is an introduction to the next class of grammars called S L R 1 or simple L R 1 grammars. So, it so happens the next topic is S L R 1. So, let me mention what happens there. So, we actually compute what is known as the follow set of the non-terminal S whenever there is a reduction, we compute the non the follow of the left hand side non-terminal which happens to be a dollar. So, if we want to do a reduction then we do it only on dollar and on plus and minus we do a shift this actually resolves the conflict and makes the grammar go ahead with the same parsing strategy. So, doing this is similar to having an end marker such as hash that we had here. So, if we had a hash here S going to E hash then this state would not have been a reduced state it would still have been a shift state. So, the reduced state would have been the next one you know S going to E hash dot. So, the assumption here is the input no matter which syntax error you know occurs in the input there will always be one hash symbol coming in. So, if the hash symbol itself is making missing then the parser stops with an error somewhere in the middle, but if the hash symbol definitely exists then it can go on you know. So, it will definitely read that and if there is an error it provides an error otherwise it goes on. So, the hash symbol makes this grammar L R 0 and removing the hash symbol which is a marker in the input makes this non L R 0, but fortunately there is another way of breaking this type and that is the using the S L R 1 strategy. If the grammar is not L R 0 we try to resolve conflicts in the states using one look ahead symbol L R 0 we never used any look ahead to resolve the conflict here we try to use the look ahead symbol. So, how do we do that? We saw that the you know expression grammar of course, even the simplified expression grammar is not L R 0. So, let me show you the grammar here. So, this is S going to dot E etcetera etcetera. So, this is the full expression grammar S going to T E E going to E plus T E going to T T going to F star T T going to F T going to F going to parenthesis E parenthesis and F going to I D. So, to begin with we have S going to dot E and then we add the closure items we get state one by advancing the dot for this particular item and for this item as well. So, we get these two items in the state number one and there are no more items to be added by closure because there is nothing after the dot here and there is only a terminal symbol after the dot here. So, it is easy to see that there is a you know shift reduce conflict here right. So, similarly you know this thing going further we get this state T going to F dot star T and we also have it has the item T going to F dot as well. So, again there is a shift reduce conflict this is a reduce item this is a shift item. So, in both these states there are shift reduce conflicts and how to resolve it you know that is the discussion we right now are going to have. The expression grammar is not L R 0 that is what we saw just now. There are the state contains the items T going to F dot and T going to F dot star T this has shift reduce conflicts not only that this state S going to E dot and E going to E dot plus T also has shift reduce conflicts. So, what we do now is consider the reduce item T going to F dot. So, this has the symbol T the non terminal T on the left hand side of the production T going to F. So, we consider the symbols in the follow set of T. So, recall that follow set of T says these are the only symbols which can legally follow T in any sentential form. So, it is fair to consider the symbols which follow this particular non terminal and say for those symbols. So, in this case plus right parenthesis and dollar these are the three symbols which can be in the follow of T. So, we say reduction by T to F can be performed on seeing one of these symbols otherwise the sentential form is you know incorrect. So, we cannot make a reduction by T at T to F. So, seeing one of these symbols in the input and you know since shift requires seeing star in the input that is here. So, there is no conflict between the reduction and the shift. Shift says C star in the input and our new strategy says reduction by T to F provided the next input symbol is either plus or right parenthesis or dollar. So, these are the only symbols the follow T symbols are the only ones which can legally follow T in any sentential form. So, the reduction by T to F when one of these symbols is seen is obviously correct. So, when shift is you know reduced conflicts are resolved using the follow set the grammar uses SLR 1 strategy and if we can indeed resolve all the conflicts in this manner then the grammar is said to be SLR 1. So, we saw how to you know resolve conflict in this case right. So, in this case also we can do that. So, we consider the follow of S follow of S is just dollar. So, reduction on dollar and shift on plus again the conflicts can be very easily eliminated. So, this grammar happens to be SLR 1 even though it is not LR 0. So, now how do we construct the SLR 1 parsing table it is fairly straight forward. So, we again build the set we build the LR 0 automaton as usual and once it is built parsing actions for straight i are determined using the follow symbol. So, one if there is a shift item alpha a going to alpha dot a beta and alpha a dot beta is in some other straight i j. So, this is straight i this is straight j right. So, we add the action i comma a equal to shift j to the table when. So, we are looking at the next symbol and then making it a shift whereas, in the case of a reduction we set action i comma a equal to reduce by a to alpha for all the symbols in the follow of a that is it. So, for the item S prime going to S dot we set it as accept on dollar and any shift reduce or reduce reduce conflicts in the table after filling all this implies that the grammar is not SLR 1. The go to part is as usual. So, we have a going to alpha dot a beta in the straight i and a going to alpha a dot beta in the straight j. So, we set go to of i comma a equal to j. So, this is and any other you know entry is made as error. So, here is an example of a grammar that is not LR 0 and the grammar is definitely SLR 1. So, again the grammar is S prime going to S, S going to ASB and S going to epsilon. So, I have chosen this example because of the production S going to epsilon. So, straight 0 contains the first item S prime going to dot S and then S prime going to dot ASB and S prime going to dot are added to it. So, in some text books instead of adding the item S going to dot it is indicated as S going to epsilon dot which is perfectly, but be careful you one should not you know generate the next item S going to epsilon dot again. Now, S going to dot is the only item that can be generated which of course, can be written as S going to dot epsilon, but we should not regard epsilon as another symbol and generate one more straight S going to epsilon dot that would be an error. Then we generate these states S prime going to S dot S prime going to dot ASB you know A dot S B dot ASB and dot S going to AS dot B and S going to ASB dot. So, if you look at the straight number 0 this epsilon production and epsilon item S going to dot it collides with these two you know. So, this is a reduction whereas, these two are shifts. So, there is a shift reduce conflict in straight number 0 and again in straight number 2 as well this collides with these two. So, here we have a reduce item and these two are shift. So, now suppose you know in both the cases the concerned non-terminal is S on the left hand side. So, let us consider the follow of the non-terminal S that happens to be dollar and B that is very easy to see because after this you know after this S would only be a dollar and here after the S there is a B. So, dollar and B are in the follow of S. So, if we say that on dollar and B it is a reduction and on A it is a shift it resolves the conflict in this state and similarly in this case again dollar and B indicate a reduce and A indicates a shift that again you know resolves the conflict in this state as well. So, one can fill up the SLR 1 table using these states now. So, on 0 on A it goes to straight number 2 and it is a shift on B it the symbol is in the follow therefore, it is a reduce item and again this is also a reduce action. So, for straight 1 it is always accept on dollar and for straight 2 for A we have a shift and for the other two symbols we have a reduce. So, straight number 3 on B has only a shift and straight number 4 again you know has a reduce on S to A S B and reduce on S to A S B. So, you compute the follow symbol of a follow symbols of S we get dollar and B therefore, it is a reduction in both these cases. So, we can see that there is exactly one entry in each of these slots therefore, the grammar is indeed SLR 1. So, now we saw L R 0 then we showed an example of non L R 0 now we then saw examples of SLR 1 because it uses a look ahead symbol 1 now it is time to see a grammar which is definitely not SLR 1. So, if the grammar is not SLR 1 obviously, it will not be L R 0 either. So, here is the same grammar as we saw before. So, the this grammar, but we added the production S going to A B the rest the other three productions are the same by adding S going to A B we actually make this grammar ambiguous. So, all ambiguous grammars are not L R k for any k. So, it cannot be L R 0 or even L R 1. So, let alone SLR 1, but it tells us a lot about the nature of non SLR 1 grammars. So, straight 0 contains all this straight 1 is here straight 2 is here and so on and because of the S going to dot item there is a shift reduce conflict in this state and shift reduce conflict in this state as well and the symbol that is involved is S. So, it is follow is dollar comma B and in straight number 0 a reduce on dollar and B and shift on A indeed results the conflict. So, there is no problem as far as straight number 0 is concerned and in straight number 2 unfortunately, there is already an item S going to A dot B. So, this means it is a shift on B and this says it must be a reduce on dollar and B. So, the conflict between this item and S going to dot still remains there is a shift reduce conflict even after using the you know follow symbols. So, this grammar fails to be SLR 1. So, let us take another example which is not SLR 1, this example is from the book by Aho, Lam, Sati and Ullman. The grammar is here and it is a very concocted grammar and we construct the states state 0, 1, 2, etcetera, etcetera this is fairly straight forward what is of importance to us is straight number 2. So, straight number 2 contains the item S going to L dot equal to R and it also contains the item R going to L dot. So, now the symbol R is on the left hand side of the reduce item. So, if you compute the follow of R it gives us dollar and equal to. So, again since dollar is ok, but equal to is also here right. So, this is a shift item which is shifted the symbol is shifted on the input symbol being equal to and this is a reduce item and our SLR 1 rule says it must be a reduction on both dollar and equal to. So, there is a shift reduce conflict even if you try to apply the SLR 1 strategy. So, therefore, this grammar is definitely not SLR 1, it was not L R 0, now it is not SLR 1 either. So, let us understand why this particular failure occurred in the last example or the one before. The problem is the SLR 1 parser considers only you know considers every symbol in the follow, the construction process does not remember enough left context to resolve the conflicts. So, let us take the L equal to R grammar that is this particular grammar this let us see how the symbol equal to got into the follow set. So, we start with S prime derive S then derive L equal to R. Now, this derives L equal to L that derives L equal to I D this is a rightmost derivation therefore, this must be derived first and then L 2 star R is applied and we get star R equal to I D. So, now equal to you know is in the follow set of R that is easy to see because this is a sentential form. The problem is the you know it is not possible to reduce the R alone to L if at all we reduce it must be star R reduce to L and it is not possible to have any reduction of R to L because you know we really do not have a production of that kind the only production we have is star R being reduced to L L going to star R is the only production whereas, in this case it says you know let L be reduced to R right. So, the reduction of L to R or the R to L can never happen in any sentential form. So, this is the basic difficulty the following rightmost derivation in reverse does not exist at all that is the direction of L to R. So, so that is we have let us say R equal to I D which gives us L equal to I D then gives us I D equal to I D. So, if we had this then we would have reduced L to R. So, similarly reduction of R to L on its own cannot happen. So, on equal to the moral of the story is on equal to the reduction should have been star R to L and it is never correct to reduce you know L to R just because of you know the here is the reduction from L to R, but it was not because of the equal to symbol, but because of a different reason. So, we will never get a sentential form and a derivation in which we can reduce L to R on seeing an equal to that would be incorrect. So, this is the reason why the SLR 1 strategy failed in the previous example. So, if we try to generalize the above whatever I said here the point is in some situations when a straight I appears on the top of the stack a viable prefix beta alpha may be on the stack such that it is not possible for beta a to be followed by a in any rate sentential form. So, in other words if we actually have you know a very limited follow then the situation can be rectified. So, here we have a general follow and equal to gets into the follow set right. So, it gets into the follow set of R, but otherwise if we have a limited follow then we would actually store enough of the left context to make sure that such you know things do not happen. So, this is the basic idea let us see how to implement it in the next class of grammars called L R 1 grammars and L R 1 parsers. So, what we really try to do here is we form items which are of the form a going to alpha dot beta comma a and a is of course, called as the look ahead symbol. So, this is nothing great on its own, but the way we actually derive states using such items is very different in this case. So, look ahead symbols have no role to play in shift items, but the reduce items of the form a going to alpha dot comma a a reduction is valid only if the input symbol is a. So, this you know input symbol actually is some kind of a limited follow that we mentioned in the last slide. So, then let us also finish of this definition of validity and L R 1 item a going to alpha dot beta comma a is valid for a viable prefix gamma if there is a derivation S deriving delta a w by right most derivations then we apply the production a going to alpha beta. So, in this case we consider this entire derivation and a to alpha beta has been applied. Now, if the first set of w that is the first symbol of w is actually a then this particular item is valid for the sentential form gamma equal to you know with the viable prefix gamma equal to delta alpha if w is empty that is a null then a must be dollar. So, in both these cases this item is valid for the viable prefix gamma which is equal to delta alpha. So, let us take an example S prime going to S and S going to A S B or epsilon. So, consider the derivation S prime going to S and S giving A S B. So, now you know the production applied at this point is S going to A S B. So, the handle ends at this point. So, this is dollar right end of the terminal string. So, a A S and A S B these are all the viable prefixes. So, the item A S going to A A dot S B comma dollar is valid for the viable prefix A. So, A is a viable prefix that I already mentioned. Now, the production which has been applied is A S B. So, if you A S going to A S B. So, here the production applied was S going to alpha beta. So, the w part you can see is empty. So, A is must be dollar which is indeed the case. For the second one we consider the item S going to A dot S B comma B and derivation is S prime giving S, S giving A S B and that giving us A A S B B. So, the production which has been applied at this point is the S going to A S B in the middle. So, the w part is this w B right and the viable prefixes are A A A A S and A S B. So, we look at the viable prefix A A and since w is once symbol B and the symbol B here also matches we know that this is valid for the viable prefix A E. So, how about the item S going to dot with a look ahead dollar? So, derive the null string S prime going to S going to epsilon. So, w is empty again. So, the symbol look ahead symbol must be dollar the only possible viable prefix is epsilon. So, everything is ok here and the last example S going to A S B dot comma B is valid for the viable prefix A A S B. So, again the same derivation. So, we have applied the production S going to A S B here. So, the last B is the w and that is the symbol here as well. So, that takes care of viable prefixes and let us proceed further. So, here we have an L R 1 grammar example and the set of items the automata and the table are all shown here. So, let us understand the procedure for constructing the set of items first and then move on to filling the table and so on. But in this slide what I want to show you is that each state contains many types of items. So, here is a reduce item for example, S going to dot and here we have shift items. This state also has reduce item and shift item this state also has reduce item and shift item, but the manner in which we are going to fill the table is going to be slightly different. So, even though we have many reduce items and shift items in each state this grammar is still L R 1 you know if you look at this particular table you can easily see that there is exactly one entry in each slot. So, the grammar is indeed L R 1. So, let us now understand how to construct the sets of items. The procedure is similar what we have is a closure procedure here also. So, we always begin let us say in the state we have the item S prime going to dot S comma dollar. So, the first symbol after the dot is a non-terminal. So, now we must add you know for the closure operation we must add items with starting from this non-terminal S. There are two of them S going to dot ASB and S going to dot. Now, the closure operation is very simple. So, what we consider is the symbols after the you know non-terminal S and concatenated with the look ahead symbol here. So, after the non-terminal S there is no symbol that is null string, but there is a dollar here. So, the concatenation of these two uses dollar and we take the first of this string and those symbols are actually listed as the look ahead symbols for the items that follow in the closure. So, here for example, the procedure says for each item A going to alpha dot B beta comma A in the item set I and we have a production B to gamma then consider each symbol in the first of beta A. So, here is the rest of the production after B and concatenated with the symbol A. So, that is the first of beta A. The reason we mention first of beta A and not a particular set of symbols is beta could consist of non-terminals. So, it could begin with non-terminals in which case there will be more than one item in the first set and it is possible that beta is null. So, this A which is definitely non-null takes care of producing at least one item for the first set. So, we form the items of the form B going to dot comma B. So, that is done for each of these you know elements in the first of beta A and add the item B going to dot comma dot comma comma B to the set of items B. So, that is how we add these two now this state you know does not grow because of the closure whereas, here we have A S going to A dot S B comma B. Now, after the S we have B and the look ahead is B.  So, we have little B as the look ahead in these two and the first part S is S going to dot A S B and S going to dot. So, this is how the closure operation is applied in the case of L R 1 items. So, basically we are trying to send the restricted follow as part of the item itself in the form of a look ahead. The go to is as it was before. So, if there is a if there is an item A going to alpha dot X beta with a look ahead A in the item set I. Then we form a new set I prime which contains the items A going to alpha X dot beta comma A. So, this part does not change in the go to then we form the closure of this particular go to. So, this particular I prime is actually made to undergo a closure operation and that gives us the go to set. So, let us see that in this example. So, state 0 we applied the closure and we got this and now to get state 1 we advance the dot by one position. So, that gives us S dot comma dollar. So, that is it here and state number 2 is obtained by advancing the dot after the A. So, we have S going to A dot S B comma dollar. So, that is the item here and then we get these items because of the closure operation. So, observe that after the dot after the S we have a B and here is a dollar. So, this is B dollar and the first of B dollar is just B. So, that is why these two symbols are B and from this item we have A S going to A dot S you know sorry this item S going to A dot A S B comma B gives us S going to A dot S B comma B. So, and then we add a few more items because of the closure operation. So, this is the example for creating the go to sets and now let us see how these two can be put together. This procedure is very similar to what we had before for each item set in C and each grammar symbol X if go to of I comma X is not equal to 5 and go to of I comma X is not in C grow the item set C rather the set of items C and add go to I X to it. So, C becomes better bigger set of item sets rather. So, each set in C above corresponds to a state of the DFA in this case it is called the L R 1 DFA and again this DFA recognizes viable prefixes and contains only those items which are valid for the viable prefixes that reach that particular state. So, getting back to this example. So, we have seen parts of this example already. So, here is state 0. So, we start with this item S prime going to dot S these two are added by closure then we get state 1, state 2, state 3 and state 4, state 5, state 6 and state 7. So, here is the DFA corresponding to it and here is the you know table.  So, we add reduce by S to epsilon and because of this dot S we have a go to entry as well. So, similarly for state number 1 we have just an accept you know there is nothing more possible this is S prime going to S dot and dollar and dollar it accepts. And for state number 2 on a on the symbol a we have a shift to state number 4. So, that is because of this and on a this is a reduction and on a b the reduction is possible by S to epsilon and this item gives rise to a go to that is go to number go to state number 3. So, in this manner you know we fill 3 as well which is just a shift on b and for state number 4 we have a go to that is state number 6 and then we have a shift because of this a and we have a reduce because of this. So, that is on b. So, you observe that even though there are many shift and reduce items in each state we really do not have more than one reduce or shift action in each of these slots in this particular table and therefore, this grammar happens to be L R 1. So, we will end the lecture here and continue with more examples in the next lecture. Thank you.


back to another video. So this video we're going to pull upon a couple of techniques we've learned in previous videos and we're going to be using VBA to help us create a very basic calculator. So what we'll be doing is we'll be using the input box method that we looked at in a previous video to be able to gather two pieces of information or more specifically two numbers from the user and we'll be building a basic calculator that will add those two numbers together and it will then paste the result into our Excel spreadsheet. So the code is going to look very familiar to what you've seen already but obviously it hopefully will help tie some stuff together to show you some actual real-world examples or real beneficial examples of putting the code and using it in Excel. So the first thing we need to do well actually we're going to do a lot as we progress along but we'll just jump straight in and obviously talk through the code as we do it. So as always we need to do our subroutine so we'll put it call it a simple calc for obviously simple calculator and we need to then define our two variables to start with. So we're going to have two which would be number one and number two or num one num two for short. So we do dim num one as integer and secondly we'll do num two as integer so because they're both integers and to sort of help tidy up keep our code nice and tidy we can code them on the same line as we've done here rather than doing a dim num two again on the second row. So we're defined both of our numbers as integers. So the next thing we now need to do is obviously set what value is going to be for each number. So the first one so num one is going to be equal to input box and for this we'll say tell me number one. Cool. So that first one is going to say tell me number one which in short basically says get getting the user to provide the first number and actually that's probably a better way of writing this. Just put first number and then for the second one we can then do num two is going to be equal to again input box input box and we'll do second number question mark close brackets and then once we've now gathered our two pieces of information so as the user is doing this they'll get the first input box they'll put a number in they'll then having submitted that they'll receive a second input box to provide the second number. So the next thing we now need to do is create a third variable what's going to be our answer. So you don't have to do this but I just like to stick with this process because it helps again keep everything nice and tidy. So report calc result is equal to num one plus number two and then simply all we're going to do with that is we'll then go into our file and we'll put let's say sheet or sheets so we want to go into sheet one we then want to go into the cells of one one and the value is going to equal, focus on the equal sign calc underscore result as simple as that. So again just to step through this we've defined both of our numbers as integers so whole numbers no decimal places we're going to have a pop-up box what will give us obviously the ability to store the first number and then the second input box will then give us the ability to store a second number. Once both of those variables have been captured we can then obviously get our last result here and we'll understand or they do the calculation of number one plus number two what will be stored as calc result and then lastly we're defined where we want to paste the value and obviously this is defined here so this first cell in column or cell one row one of column one and obviously that the value of that is going to equal our result. What we can just do lastly again is put another developer tab and do it insert a button and we'll do that we'll also assign it to the simple calc subroutine and let's just rename our button to calculator like so. So what we don't need to do is just simply run our code so when we click our button you can see we get our first input box and as we wanted it says first number question mark so we can now provide a number let's go number five as we click okay you can see that their first input box was closed and then replaced with our second and so that first number has now been stored in our variable of number one we're now gone to our second number here so let's do five again and do okay and upon doing that you can see that five plus five is obviously ten and that has then been stored into our cell cell one at the top here so we've been able to just create our very simple calculator what we can do is just to play around with this bit more so touching on a couple of extra bonus things here is when we're actually putting this value into our cell at the moment obviously just says the number ten what we could do is add a bit more text here using the sort of the strings and let's say we wanted to say the result is and then what obviously the result is so all we now need to do here is in quotations we can put the calculator result is just a little colon and do a quotation so you can see we've done these two quotations obviously telling it its string and I've just included the space at the end here just so there is a space between our string and the result and lastly I was going to do an and symbol after our little custom bit of string and the calculation just to stick it all together so if I was to now run this again let's do this time first number is ten and the second number is two and do okay you can see that we now have a nice bit of text here will actually instructs the user what they're seeing and obviously they know that number is obviously the result of the calculation and it now says the calculator result is 12 which we know is ten plus two so for this basic calculator with that we've used the plus if we want to change it and make it either multiplication division or subtraction all we need to do is just change this symbol in here and let's go for multiplication this time so let's change that into a multiplication or multiplication if I can say it so this time if we do our calculator select calculator and we'll do five there's a first number we'll also do five as the second number select okay and you can now see our result is changed to 25 and again we're still got that text in there just to show the user what they're actually seeing because obviously we're always referencing that same cell of cell 11 obviously the value is always going to override whatever the previous value was so there you go we've just now completed our first actual process and created a very basic calculator using Excel VBA as we go through there's a couple of little bits we need to go over in in separate videos but we'll eventually look to build a dynamic and obviously more advanced calculator than this one and we'll be doing that I'll say in a future video so make sure you stay tuned for that to ensure you see that video when it does come out because that will be a good one do ensure that you are subscribed to the channel and you've got that Bell notification clicked so you're notified as soon as that and our other videos come out if you did enjoy today's video please don't forget to give the video like it is it's greatly appreciate by me and obviously helps that all important YouTube algorithm and also just make sure that other people are able to see this video and learn something new if they weren't already aware of it if you do have any questions as always please just drop a comment below this video and I'll get back to you as soon as I can and lastly thank you once again and we'll see you in the next video


today's YouTube live day. So there's a couple things I want to talk about. First, I kind of want to recap my trades of the day and then I want to talk about what the stimulus checks and what that means kind of for the stock market. So let's start in the morning. So in the morning guys, in the morning we had a stock called CHEC, C-H-E-K. This is a former runner. So all of pre-market it was just churning and pulling in a lot, a lot of volume, right? And what we've been noticing in this market guys is the more volume, the more demand that these stocks have, the harder it is for it to go down. So in the morning, I wasn't really interested in shorting CHEC, right? Because it didn't really fit my process. It was the hot chick, it was day one, it traded abnormal volume and it was above VWAP. All of those warning signs told me to avoid it, don't touch it, don't do anything. You know, what I want to see on these stocks guys as a short seller is I want to see these stocks top out, okay? Go down and tank, do a lower high and I am going to short that lower high. So I want there to be an initial top set so that I know where I'm gonna stop out, right? I wanna know where I'm gonna stop out. So on CHEC, I pretty much avoided all of pre-market. I'm pretty sure I even went long, very early in the morning and I shared that too. So pre-market, I am looking to either go long these stocks or just avoid them on the short side completely because what I want to see is I want to see them tank and then I will attack it when they tank. So in the morning on CHEC, I was trading around $4 to the $4.50 range and I wasn't really interested in it because it was the hot stock of the day at the time. There was really nothing else moving. Bow went long in the morning and to me if bow is going long in the morning and I don't want to short in the morning, that's just a sign that, okay, let me have it on the side radar and let it do its thing and then when the time is right, I'm gonna come all over it. So what ended up happening is in the morning, it made a top around like the $4.44.50 level which is a half dollar mark and now it tanked down to like 410 or 405 and it rebounded, right? If that rebound fails, that is the area that I want to short in risking that pre-market high of the day. So I would short that bounce and I'll be risking the pre-market high of the day on it, right? And I told the guys in the room that for me that trade is just a little bit riskier. I want to kind of have it break the $4.00 whole dollar mark. So even me, I was a little bit scared to short that bounce initially in the morning because there was a lot of volume. I wanted it to tank even harder under four, giving it more resistance in the morning, that way I would attack. So Bao actually shorted that lower high. So think about it, Bao went long pre-market and Bao went long in the morning as soon as it had a lower high, as soon as it topped out, he went short. He went short that first trade. And I'm like, okay, Bao went short, makes sense.  So I want it to take under $4.00 and then that bounce back up, I want a short. Everyone is saying that my paper trade on check worked.  Anyway, so what ended up happening on check is pre-market it went straight up, okay? At the open, a chat room came and pumped it, they were not able to pump it hard, it tanked. It tanked under four. At this point, I'm telling everyone in the room, it broke under four, if it bounces, I am going to short it. So it tanked under four, it went to like 390, okay? It went to 390 and I basically resorted that bounce 398 to $4.00 and covered at 360. So now all of a sudden, I didn't trade a pre-market, I avoided it at the open and now as it broke down $4.00 support, I shorted that lower high as now longs that were trapped, we're looking to exit. Does that make sense guys? So that's number one. Number two is SGLB. So as check was tanking, actually give me one second. Thank you. I'm going to run my few thoughts as to how are you going to tank. Thank you. All right. And the, very, very good. Can I follow? Okay, I'm going to bring it. Don't worry. You want to stay over. Thank you. Hey guys, sorry, I don't know. Just want to make sure that you guys can see me and hear me. I'll explain what happened. Just want to get to confirm that you guys could hear me. Anyone? All good. Okay, sorry. So yeah, I have a plumber at the house. Like I've been having like a leak for like a week, two weeks and the plumbers just told me that they finished. So I just wanted to walk them out and make sure that they got out safe. All right. So I'm back. So as check was, okay. So let's go back, right? So check was the hot stock of the day that failed pre-market highs that had a lower high that a chat room came. They failed to pump it. It broke for a dollar whole dollar and it broke under view app. Now it's dead.  So when this happened guys, we talked about something called the flow of money. So everyone that was trading that hot stock, right? Everyone that was all over it, where are they putting their money next, right? And in the market guys, it's not like a one and done, right? It's not like you take the money and then if check tanks the day's over, you know, some of these traders, some of these new traders, they're pretty much gamblers.  If there's a new stock moving, if there's another table that's hitting, they're gonna move all their funds here, right? So that is what we call the flow of money. It's something that we kind of, this is an observation that we've kind of talked about and kind of made a little bit more popular as well. So when that happens, when check tanks, when the hot stock of the day tanks, the money flows somewhere else. It goes into a different stock. These new traders, these Robinhood traders, they start gambling on the next hot stock that is moving, right? So that was SGLB guys, which is now at high of the day. And holy shit, that check trade was sick, right?  Anyway, so when SGLB started to take attention is when we started to warn everyone in the room to be careful, right? So the reason why you join MIC is not only to kind of learn from us to kind of get mentored, it's also to kind of not make the mistakes that we do in the past, because to be honest, knowing what stocks to avoid and knowing what stocks to trade are the ones that are the most important as well. So on SGLB, as it was trending up, it went to 650, it went to 675, it went to seven, it went to 720, et cetera. So I'm telling the guys in the room, there is a very, very key support level on SGLB, which is $6.50. That is VWAP and that is a half dollar mark. So I mentioned to the guys in the room, the same way that I want to check to break under four and bounce, I wanted SGLB to break under 650 and bounce, and that would be the trade that I would take on it. So while it's trading at seven, I'm not touching it. When it breaks to 650, I'm looking at it, okay? Now I'm thinking to myself, okay, tank this motherfucker as hard as it can. The harder it's gonna tank, the less, the more viable shorting the bounce is gonna be, right? So in my head, guys, when this broke 650 and went down to 620, I said, oh my God, please bounce. Let me look for a VWAP rejection, and that will be my trade. So I posted my trade in the room, I shorted 650 and 60, I shorted 650 and 660, and I covered at 625. So let's review, check. I shorted the bounce when it broke under four, around like 398, four, and I covered at 360. SGLB, when it broke under the 650 support, the key support that we identified, and then it bounced back to 650, 660, I shorted and it went down to 620 and I walked away. At this point, guys, I'm up $1,000 on the day. I made like 500 on this stock, I made like 600 on this stock, 11, whatever the number is, right? And usually for me, guys, like everyone is at a different stage in their trading career, everyone's at a different level. And for me, I average about $2,000 to $10,000 a day, which thank God is a lot of money. And on a day that I make a little bit less, something goes wrong in my brain. My brain tells me I underperformed. My brain tells me I didn't make enough money.  And oftentimes very early in my career, guys, I let those negative thoughts and I let that negative energy force me to stay at the desk and force me to over-trade and force me to turn to convince myself that a C plus setup was an A minus setup, okay? And as I've matured, as I've traded, as I've lost money doing this, I've recognized that there is one rule. There is one rule that has changed my trading forever and that will change your trading forever. And it is called the zombie rule, okay? This is something that we've created at MIC. This is something that every single other community is now paying attention to because they are interested and they've realized the importance of this. So for me, the zombie rule is the most important thing because in trading, guys, in trading, anyone can make money. The problem is that most people cannot keep the money in their accounts.   And to me, what I remember in the past is if I just walked away from these tables, I would have so much more money. So as I trade, I remind myself that sometimes I need to walk away from these screens. If not, I'm gonna sit here all day and try to scalp and scalp and scalp and scalp and I'm gonna end up slowly bleeding out, bleeding out, bleeding out, bleeding out. Now, the zombie rule, guys, is something that I gave everyone homework on if you were a lifetime member. So I mentioned to the lifetime members we had a trader clinic. And basically we recognized, or I kind of gave them homework and said, guys, for this week, this week that we are in now, I want you guys to use heart stops only and I want you guys to walk away at zombie times and I want you guys on Friday to update me with how your P&L went so that you guys can believe it. And I already have members that are DMing me today saying that they saved their asses on SGLB and check by walking away at zombie times, guys. So think about it. This process is the same process that I use to become a millionaire. I am up over a million dollars in P&L in 2021 already and that is because I am being able to walk away and lock in my money, okay? So this makes sense, guys. This makes sense. Do you guys understand why I'm shorting these stocks when they break down? Do you guys understand why I am avoiding these stocks on the way up? Do you guys realize that when I make my money, I want to be able to walk away as fast as possible? Because if not, these motherfucking screens are gonna take all my money, okay? Does that make sense, guys?  Is there news? Wow. Anyway, oh wait, that brings me to, okay. GameStop is tanking, that brings me to my second point, okay?  Wow, it's about to halt down.   Okay, okay, okay.  So let's talk, let us talk about the stimulus check and what the hell it means for the stimulus check. Oh, I can't, I'm giving you a sec.  Guys, look at this price action on GameStop. Look at this price action.  Give me a sec, give me one second. Holy, is there news? Wow, this is so tempting. I have to stop, no I can't. No, I'm not gonna do it, I'm not gonna do it. I just messaged my broker, I told him not to let me.   I'm gonna start itching. Jesus Christ, bro, what the hell, I've never, geez, you guys saw that too. Yeah, I'm done, all right, let's talk, let's talk, let's talk. So what does the stimulus check mean for the stock market, okay? So what happened last time, guys, is when the stimulus check came in, everyone was locked at home and everyone was quarantined and everyone was stuck pretty much in day trading, right? The only option they had was to take that stimulus check and put it into the stock market. Now I think that a very similar thing is gonna happen this time, guys. I think every single person that puts their stimulus check into the stock market again this time is not going to be rewarded as much as last time. Now let me explain.  And in my opinion, I think we are still gonna get these crazy runners. I think all of the money is gonna come to the small cap stocks. I think there's gonna be a lot of speculation money into Tesla and Bitcoin, but I don't know if these moves are gonna be as bizarre and as abnormal as they were in the past, guys. So my advice with your stimulus check, if you are going to get it, is not to put it into GameStop, is not to put it into AMC, is not to put it into these meme stocks or Dogecoin or Bitcoin. My advice would be take that 1400 and invest in your education so that you could learn how to turn that 1400 into $10,000, guys. I see a lot of people that as soon as they make money, they go out and they buy a BMW. As soon as they make a little bit of money, they're gonna spend it on a Gucci belt. But don't you guys wanna learn how to buy the BMW store? Don't you guys wanna learn how to buy a lifetime of Gucci? With the trading that I've made today or this year or whatever, if I could pretty much buy the entire Gucci store every single year if I wanted to. So my advice, guys, on these stimulus checks is do not use it as gambling. Do not treat it as some sort of lottery ticket.  And if you wanna put it into the stock market and you don't wanna put it into education too, okay, do what you're doing, but for the love of God, don't buy GameStop, don't buy AMC, put it into like an Amazon, put it into like a Facebook, put it into something that is secure and solid that is gonna generate you income. If not, guys, if not, that 1400 that you make is gonna come into right back into my pocket because I'm gonna be shorting these mean stocks that you are buying. Does that make sense? NASDAQ is tanking.  But do you guys see what I'm talking about, guys? This market has been, the 2020 and 2021 has been the best stock market in history for day traders because there's so much dumb money out there. Every single person is treating this stock market as gambling as the casino, but there is an edge here, guys. There is ways to make money. You could beat the house. You are the house in day trading, right? So to be honest, the more uneducated money that flows into the stock market, the more money I make, the more money MIC members make.   So guys, treat this as a job. Treat this as a career. Take this seriously, okay? Take this seriously. And if you do, I promise you, you will make so much money that you literally don't know what to do with it, right? And that's, thank God, that's how I feel right now. I'm making so much money that I don't know what to do with it.  For seven years, I've been working so hard to get to this point where there's so much dumb money out there, so much uneducated money that it's making my trading and making my life so much easier, guys. So this doesn't make sense to you guys.  Wow, about AMC is going lower. Great trade on AMC, check that paper trade is down 50 cents a share since we started. So do you guys have any questions for me? What was my daily goal prior to killing it? My daily goal was never a P&L goal. My daily goal was just to be green, man. Even if I was green, $1.  Wow, SGLB is at $8, guys, $8. We stopped trading it at $6.50. And I guarantee when I go back to my computer and I see the PMs, I'm gonna see at least 10 members that said, hey, I went long as zombie times, thank you. I went long as zombie times, good job, guys. Yeah, so I mean, this is the process, guys.  Every single day the traders see me inside MIC and we pretty much preach what is making us money, right? So, you know, all these other communities, they got email alerts, they got voice alerts, they got text message alerts, they got screen share alerts. And they're pretty much pumping dumping all day.  We are teaching you guys, honestly, the same strategies that I'm using, the same strategies that Bow is using that are repeatable to make you money in the market. And I know a lot of people are hesitant and I know a lot of people are kind of scared. They don't trust that they've been scammed in the past and they don't wanna learn again. So we're actually running a promotion, guys.  So you'll get your first month for $97. So for $97, guys, you guys could be here for a month and you could judge for yourself if we are a scam or not.  So do you guys have any questions for me? What is the must have scanner in your opinion in the seven years that I've been trading? I have never paid money for a scanner once. Why pay $300 for a scanner? When you could pay MIC 200, get all the scans for free, get education and get mentorship. A scanner is the biggest waste of money because you do not know what to look for as a scanner. So any other questions, guys? Or else I'm going to wrap it up for the day. Yeah, that's pretty much it. Last week was like a pretty big week for me. Not in terms of P&L, but in terms of mentorship. I made a YouTube live on Monday. I made an Instagram live on Tuesday. I attended Tasha's webinar on Wednesday and I did a lifetime member webinar on Thursday. So what other community, what other mentor is creating videos for you four days a week? And we do this because we really care and I just really needed a day off on Friday, so I appreciate you guys letting me take a day off on Friday, but I'm refreshed. I'm feeling good. I had a porter house for dinner last night. And yeah, I made $1,000 today, which pays for my dinner yesterday 10 times over. And you know what? It really isn't a small day. So sometimes we just need to kind of step back, humble ourselves and realize that, you know what, if we're able to show up and make $1,000 a day with no stress, that's life changing money. So thank you guys and check out the website if you guys wanna get your first month of MIC half off. I will see you guys back in the room and I will be in PMs for the rest of the day, helping you guys in the room. So have a good day.