0% found this document useful (0 votes)
9 views1 page

CH List Cs Word

Uploaded by

Taranpreet Kaur
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOC, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
9 views1 page

CH List Cs Word

Uploaded by

Taranpreet Kaur
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOC, PDF, TXT or read online on Scribd
You are on page 1/ 1

“tate, .

: . 8 oo,
—~ Seg + -4+5- > -. -- -~
. : [ oO» cher sob ee a vt v oe
( 4) CL we [- C is n v6, Wok (.! fe* J
"8 Skills : 8.1 INTRODUCTION
On, Uch sequences arise naturally in many real-life situations. A year has 12 months (January, February,
re Shoulg March, April, May, June, July, August, September, October, November and December). The
months of
the year are in a sequence. After January, it will always be February. It is impossible to jump from
March to July because it has to go in a sequence. So, we say a Sequence is an object that contains
multiple items of data. The items are stored in dsequencéjone after the other such as a sequence of
events, movements, items, or a ‘sequence in which a player records (music) with a sound recorder/
sequencer. Consider the example of a sequence of cars as shown in Fig. 8.1.
} 2 were ce ms
A } ie : ; 7 a rE x —_
ts BS 5 tg
ae |
Q rv M ae eof,
SS - V
Sequence of Cars
Fig. 8.1: A Sequence of Cars
As is evident from the above figure, there is a sequence of cars and each car becomes an element/
item of this particular sequence. Here, we have a grey-coloured car, a blue car, a red car and so on.
So, all of these cars combined together form_a sequence. Python also supports sequence which
:.',..e
can be considered as containers and in those containers certain Items are stored. A sequent Vv
aa aes : : vee ence.
may have repeated items in the list. The number of elements is called the length of the sequente..
The various sequences available in Python are shown in Fig. 8.2.

You might also like