Written by students who passed Immediately available after payment Read online or as PDF Wrong document? Swap it for free 4.6 TrustPilot
logo-home
Document preview thumbnail
Preview 4 out of 43 pages
Summary

Samenvatting informatica

Document preview thumbnail
Preview 4 out of 43 pages

Dit is een samenvatting van alle te kennen methodes of functies in de API van 1ste bachelor industriële wetenschappen. Ook alle andere leerstof van dit vak staat in de samenvatting. De prof die dit vak geeft is Helga Naessens.

Content preview

SAMENVATTING INFORMATICA
Deze gids bevat een uitgebreide uitleg van alle Python-functies, databanken-functies, HTML-
tags en CSS-eigenschappen uit het oorspronkelijke API-document. Elke functie/tag/eigenschap
wordt beschreven met wat je erin stopt, wat eruit komt, wat er gebeurt, en bevat voorbeeldcode
of gebruik. Ook basiskennis over informatica staat hier samengevat.


Python

Standaard python functies

abs()

invoer: int of float
uitvoer: int of float
wat: absolute waarde
voorbeeld: abs(-5) # 5

input()

invoer: str of niet
uitvoer: str
wat: vraagt invoer aan gebruiker
voorbeeld: naam = input(“wat is uw naam? “)

open()

invoer: “name”, “mode” : r , w , a
uitvoer: bestand
wat: opent een bestand
voorbeeld: f = open(“bestand.txt” , “r”)


print()

invoer: object, end, file
uitvoer: geen
wat: print naar scherm of bestand
voorbeeld: print(“Hallo” , end = “!”)

,type()

invoer: object
uitvoer: type
wat: geeft het type terug
voorbeeld: type(5) # class ‘int’
bool()

invoer: x
uitvoer: type
wat: zet om naar boolean
voorbeeld: Functie leeg of nul

float() , int() , str()

invoer: x
uitvoer: float, int , str
wat: variabele omzetten naar een float , int of str
voorbeeld: int(“5”) # 5 float(5) # 5.0 str(5) # “5”

list()

invoer: iterable
uitvoer: list
wat: geeft het list terug
voorbeeld: lijst = list(tekst) # ['h', 'a', 'l', 'l', 'o']



tuple()

invoer: iterable
uitvoer: tuple
wat: geeft het tuple terug
voorbeeld: tuple_vorm = tuple(tekst) # ('h', 'a', 'l', 'l', 'o')



ord()

invoer: str
uitvoer: int
wat: geeft unicode van teken terug
voorbeeld: ord(“A”) # 65

,chr()

invoer: int
uitvoer: str
wat: geeft teken van unicode terug
voorbeeld: ord(65) # “A”


len()

invoer: list of string
uitvoer: int
wat: geeft lengte van string of list terug
voorbeeld: len(“Abcdefg”) # 7



round()

invoer: int of float
uitvoer: int of float
wat: rond een getal af
voorbeeld: round( 5.6547 , 2) # 5. 65



range()

invoer: int
uitvoer: range
wat: reeks getallen genereren
voorbeeld: i in range(5) # 0 1 2 3 4 i in range( 2 , 10 , 2) # 2 4 6 8



min() max()

invoer: iterable
uitvoer: int , float
wat: geeft minimum of maximum terug
voorbeeld: min(list) max(“string”) # max volgens ascii



min()

invoer: iterable
uitvoer: int of float
wat: geeft som terug
voorbeeld: sum(getallen, 100) of sum(getallen)

, enumerate()

invoer: iterable
uitvoer: iterable
wat: geeft index + waarde
voorbeeld: enumerate(dieren, start=1)
sorted()

invoer: iterable
uitvoer: list
wat: geeft gesorteerde lijst terug
voorbeeld: sorted(getallen) of sorted(getallen, reverse=True)


Module Random

randint()

invoer: int , int
uitvoer: int
wat: Willekeurig geheel getal tussen a en b
voorbeeld: random.randint(1,10)

random()

invoer: geen
uitvoer: float
wat: Willekeurig getal tussen 0 en 1
voorbeeld: random.random()

choice()

invoer: iterable , list vooral
uitvoer: int, float, …
wat: Willekeurig element kiezen
voorbeeld: random.choice(kleuren)

shuffle()

invoer: iterable , list vooral
uitvoer: none
wat: Lijst in willekeurige volgorde plaatsen
voorbeeld: random.shuffle(kaarten)

Document information

Study
Uploaded on
August 18, 2025
Number of pages
43
Written in
2024/2025
Type
Summary
$7.11

Wrong document? Swap it for free Within 14 days of purchase and before downloading, you can choose a different document. You can simply spend the amount again.
Written by students who passed
Immediately available after payment
Read online or as PDF

Sold
0
Followers
0
Items
1
Last sold
-


Why students choose Stuvia

Created by fellow students, verified by reviews

Quality you can trust: written by students who passed their tests and reviewed by others who've used these notes.

Didn't get what you expected? Choose another document

No worries! You can instantly pick a different document that better fits what you're looking for.

Pay as you like, start learning right away

No subscription, no commitments. Pay the way you're used to via credit card and download your PDF document instantly.

Student with book image

“Bought, downloaded, and aced it. It really can be that simple.”

Alisha Student

Working on your references?

Create accurate citations in APA, MLA and Harvard with our free citation generator.

Working on your references?

Frequently asked questions