Exercises
Languages | |||||
---|---|---|---|---|---|
Remove the intermediate part |
nl
|
python
input(),
print(),
str.find(),
concatenatie,
slicing,
|
|||
Number of different values |
nl
|
python
input(),
print(),
int(),
relationele operatoren,
for-lus,
|
|||
Chessgame - Bishop move |
nl
|
python
input(),
print(),
int(),
relationele operatoren,
if\else,
|
|||
Neighbours swap places |
nl
|
python
input(),
print(),
int(),
relationele operatoren,
for-lus,
|
|||
Good neighbours |
nl
|
python
input(),
print(),
relationele operatoren,
while-lus,
if/elif/else,
|
|||
Reverse the intermediate part |
nl
|
python
input(),
print(),
str.find(),
concatenatie,
slicing,
|
|||
Replace within fragment |
nl
|
python
input(),
print(),
str.find(),
concatenatie,
slicing,
|
|||
Longest streak of equal values in series |
nl
|
python
input(),
print(),
int(),
relationele operatoren,
if/else,
|
|||
Unique values |
nl
|
python
input(),
print(),
int(),
for-lus,
list.append(),
|
|||
Remove character |
nl
|
python
input(),
print(),
relationele operatoren,
if/else,
concatenatie,
|
|||
Even values |
nl
|
python
input(),
print(),
modulo,
relationele operatoren,
for-lus,
|
|||
First and last appearance |
nl
|
python
input(),
print(),
str.find(),
concatenatie,
str.count(),
|
|||
Number greater than both neighbours |
nl
|
python
input(),
print(),
relationele operatoren,
for-lus,
len(),
|
|||
Swap places of minimum and maximum |
nl
|
python
input(),
print(),
int(),
for-lus,
list.append(),
|
|||
Chessgame - Queen move |
nl
|
python
input(),
print(),
int(),
relationele operatoren,
if\else,
|
|||
Maximum from list |
nl
|
python
input(),
print(),
int(),
for-lus,
str.split(),
|
|||
Number of pairs in list |
nl
|
python
input(),
print(),
int(),
for-lus,
range(a,b),
|
|||
Apply scale |
nl
|
python
input(),
print(),
int(),
for-lus,
range(),
|
|||
Swap columns in a 2D list |
nl
|
python
input(),
print(),
int(),
for-lus,
range(),
|
|||
Appearances |
nl
|
python
input(),
print(),
for-lus,
print() keyword argument end,
if/else,
|