Making or slicing Lesch
sluicing just
to make a slice with the list you should specify the index of the first and last elements you need to
work with.
So this is a sign of Sly's.
You should use it to make a slice and less square brackets first element call in last element.
Let's see how.
First go to brackets
then create on the list.
For example I want to make a list called operating systems or always then I want to put elements such
as Mac Windows Linux and array.
And I always separated by a comma after that print this slice left by typing the element name o s the
square brackets.
But the first element that you need to start with after the colon the last element that you need to
stop and save the file and try that on terminal
great or sliced list printed.
Well OK now let's try to change a little bit in the slice list and see the difference.
If we did not put anything in the first element if all the polling I found will recognize that and we'll
start from zero.
See that terminal right now.
OK.
If I could.
From 0 to number 3 it will print from Mac to Linux.
Now I will try from 2 to 5.
Go as you can see here it's printed the last three elements.
So if we try from two to number three it will print on the Linux
pretty good.
OK.
Now let's try to print two before the call on
great.
It just started from Linux.
Also it's possible to print that by using a minus and it will print from right to left.
Pretty good guys.
This is just a practice for you to know how to use the slice laced arm printed out.
Thanks for watching.