WEBVTT

00:00.120 --> 00:00.500
All right.

00:00.510 --> 00:04.430
So now we're talking about less than we just talked about greater than and greater than or equal to.

00:04.680 --> 00:07.260
So this one should be much shorter.

00:07.260 --> 00:13.810
In fact the total time that it will take will be less than the previous video.

00:14.760 --> 00:18.460
So it works the same way although it does the opposite.

00:18.630 --> 00:23.140
If you're familiar again just the less than bracket the angle bracket I think it's what they're called.

00:23.140 --> 00:24.120
Just remember that.

00:24.390 --> 00:25.750
So shift.

00:25.800 --> 00:29.670
And then on most keyboards is a comma so we can do things like this.

00:29.670 --> 00:36.100
So rather than selecting all books released after 2000 we just switch it to the less than sign in our

00:36.120 --> 00:42.930
select star from books wherever released here is anything below the number 2000.

00:42.930 --> 00:50.180
So if we try that select title and released year from books we do all of them.

00:50.280 --> 00:57.580
And let's do our order by again released here just to make it easier to see where we have missing gaps.

00:57.870 --> 00:58.330
OK.

00:58.470 --> 01:04.560
So we want all of these to disappear or excuse me on all these disappear and only want to select these

01:04.630 --> 01:06.860
five.

01:06.990 --> 01:19.400
All we need to do is add in our where released here is less than 2000 And there we go.

01:20.130 --> 01:20.560
OK.

01:20.760 --> 01:23.550
So that's pretty much all say about it for now.

01:23.850 --> 01:28.300
Along with that of course we have less than or equal to which works the same way that greater than.

01:28.320 --> 01:32.380
Well it doesn't work the same way it works in the same way that greater than or equal to does.

01:32.580 --> 01:38.220
So if I wanted to include the year 2000 for whatever reason I just need that equal sign after the less

01:38.220 --> 01:44.580
than sign and now we get the same five books plus the one that was written in 2000.

01:44.580 --> 01:46.710
Amazing Adventures of Kavalier and Clay.

01:47.400 --> 01:48.810
That's pretty much it.

01:48.840 --> 01:54.630
I will throw up a few exercises here if you want to try evaluating them and then moving on to some more

01:54.630 --> 01:57.450
interesting and complex operators.

01:57.450 --> 01:58.640
All right so I'm back here.

01:58.790 --> 02:01.380
I typed up a couple of quick exercises.

02:01.380 --> 02:02.790
Go ahead try these out.

02:02.790 --> 02:07.110
I'll throw up that same graphic again and I'll be back in one second.

02:07.660 --> 02:09.340
OK I'm back here.

02:09.450 --> 02:11.020
So let's go through these quickly.

02:11.040 --> 02:15.190
The first one is three less than negative 10.

02:15.630 --> 02:21.260
Well I don't think so but let's verify.

02:21.360 --> 02:24.020
You can see zero meaning false.

02:24.090 --> 02:28.970
It's not is negative 10 less than negative 9.

02:30.800 --> 02:31.760
Yes it is.

02:31.760 --> 02:37.350
It's lower than negative 9 is 42 less than or equal to 42.

02:38.300 --> 02:40.360
Ok need to add a space there.

02:41.030 --> 02:47.360
And as you would expect we get yes we get one true because 42 is equal to 42.

02:47.360 --> 02:51.030
Now on to the odd string ones it's the letter H.

02:51.050 --> 02:55.030
Lowercase less than the letter P also lower case.

02:55.300 --> 02:59.140
And if you remember to the last video of how this works H comes before p.

02:59.510 --> 03:00.580
And they both lower.

03:00.590 --> 03:05.100
So yes this should be true and it is OK.

03:05.150 --> 03:09.320
So this final one is UPPER CASE Q less than or equal to lowercase q.

03:09.590 --> 03:16.050
Well this should be reviewed from the last video because I remember that case doesn't matter.

03:16.670 --> 03:19.780
So we see that yes indeed it is true.

03:20.180 --> 03:27.410
Prickish Q is less than or equal to lowercase Q And if we get rid of the equal to this is basically

03:27.410 --> 03:28.990
a duplicate of what we just said in the last video.

03:29.000 --> 03:36.320
But I just want to hit this home that it is not lower it's not greater than they are equivalent.

03:36.800 --> 03:38.880
Well that's a minus sign.

03:39.000 --> 03:39.630
There you go.

03:39.650 --> 03:40.310
They are equivalent.

03:40.310 --> 03:42.340
As you can see we get true or 1.

03:42.770 --> 03:43.260
OK.

03:43.400 --> 03:43.960
Next up.

03:43.970 --> 03:48.510
Moving on to much more exciting much bigger and important logical operators.
