10. Glossary (order: reader text)

This appendix contains an overview of all keywords, functions, data types, operators and modules that are treated in one way or another in the 0HV120 reader.

name/symbol

category

used for

section

print(…)

function

user output

2.1

#

symbol

comments

2.2

=

statement

assigning values

2.3

input(…)

function

user input of a string

2.6

string

data type

text

3.1

[ ]

operator

indexing (string)

3.1

+

operator

concatenation (strings)

3.1.2

*

operator

repetitions (strings)

3.1.2

len(…)

function

length of string

3.1.3

[ : ]

operator

slicing (strings)

3.1.4

lower()

function

change characters to lower case (string)

3.1.5

upper()

function

change characters to upper case (string)

3.1.5

ljust(…)

function

left-aligning of text (string)

3.1.6

rjust(…)

function

right-aligning of text (string)

3.1.6

split(…)

function

split into list with parts (string)

3.1.7

join(…)

function

join list with fragments into one string

3.1.8

find(…)

function

index of first occurence of fragment (string)

3.1.9

rfind(…)

function

index of last occurence of fragment (string)

3.1.9

int

data type

counting

3.2

float

data type

real numbers

3.2

+

operator

addition (numbers)

3.2.1

*

operator

multiplication (numbers)

3.2.1

/

operator

division

3.2.1

abs(…)

function

absolute value of a number

3.2.1

-

operator

subtraction

3.2.1

**

operator

raising to a power

3.2.1

//

operator

integer division

3.2.1

%

operator

remainder of an integer division

3.2.1

round(…)

function

rounding off float number

3.2.2

bool

data type

decisions

3.3

<

operator

strictly less than

3.3.1

<=

operator

less than or equal

3.3.1

>

operator

strictly greater than

3.3.1

>=

operator

greater than or equal

3.3.1

==

operator

equal to

3.3.1

!=

operator

not equal to

3.3.1

and

operator

conditions or bool

3.3.2

or

operator

conditions or bool

3.3.2

not

operator

conditions or bool

3.3.2

list

data type

collections of items

3.4

[ ]

operator

indexing (list)

3.4

len(…)

function

length of list

3.4.1

remove(…)

function

remove item from list

3.4.2

append(…)

function

add item to end of list

3.4.3

insert(…)

function

insert item at specified position in list

3.4.3

[ : ]

symbol

slicing (lists)

3.4.4

sort(…)

function

ordering items in a list

3.4.5

index(…)

function

returns index of item in a list

3.4.6

in

statement

test for membership (list)

3.4.6

dictionary

data type

list of key-value pairs

3.5

clear(…)

function

clears a dictionary form all items

3.5

del

statement

deleting a variable

3.5

type(…)

function

analysing the type of …

3.6.1

str(…)

function

conversion to string

3.6.2

float(…)

function

conversion to float number

3.6.3

int(…)

function

conversion to integer

3.6.3

bool(…)

function

conversion to integer

3.6.3

if

statement

decisions

4.1

else

statement

decisions

4.2

elif

statement

decisions

4.3

while

statement

repetition (indefinite nr of times)

5.1

for … in

statement

repetitions (over items in a list)

5.2.1

for … in

statement

repetitions (over a range of numbers)

5.2.2

range(…)

function

defines a range of numbers (for repetitions)

5.2.2

def

statement

definition of a function (or method)

6.2

return

statement

result of a function call

6.2

None

data type

result void function call

6.5

class

statement

definition of a class

7.2

.

operator

data or method selection (objects)

7.2

Tk

class

creating a single GUI window

8.1

mainloop()

function

starting a Tk window and handle UI events

8.1

title()

function

setting the title of a window

8.1

Button

class

widget for starting an action by clicking on it

8.1.2

config()

function

setting a property of a widget

8.3.x

Label

class

widget for displaying text or images

8.3.3

Entry

class

widget for text entry

8.3.4

Frame

class

widget that bundles others to help GUI layout

8.3.5

Canvas

class

widget for drawing geometric shapes

8.3.6

grid()

function

layout (positioning) of a widget

8.3.7

pack()

function

layout (positioning) of a widget

8.3.7

bind()

function

connect a widget event to a response (action)

8.4

after()

function

starting an action after a specific delay

8.6.1

import

statement

importing all code from another module

9.1

from .. import

statement

importing part of the code.

9.1

import .. as

statement

rename a module in local code.

9.1

.

operator

data or function selection (module)

9.1

random

module

generating random numbers (int and float)

9.2

randint(…)

function

selects a random integer from a range

9.2

random(…)

function

selects a random float

9.2

choice(…)

function

selects a random item from a list

9.2

for … in

statement

repetitions (over lines in a text file

9.3

open(…)

function

opens a file for reading and or writing

9.3

close(…)

function

closes a file after reading and or writing

9.3

read(…)

function

returns the contents of a file

9.3

write(…)

function

adds to the contents of a file

9.3

seek(…)

function

searches within a file

9.3

time

module

timing operations

9.4.1

sleep(…)

function

suspends execution for a given amount of time

9.4.1

threading

module

multi threading programs

9.4.2

start(…)

function

starts a delayed Timer operation

9.4.2

cancel(…)

function

cancels a delayed Timer operation

9.4.2

Timer

data type

delayed operations

9.4.2

time(…)

function

returns the current time

9.4.3

gmtime(…)

function

converts time into human readable format

9.4.3