Skip to main content
Challenges Predicting Python output
Misc Easy Programming logic Solves: 12

Predicting Python output

Author: CyberSamSU
Points
15

Execute the following Python code step-by-step on paper (without running the program) and find out what it prints:

harflar = list("cybersamsu2026")
natija = []
for i, ch in enumerate(harflar):
    if i % 3 == 0:
        natija.append(ch.upper())
    elif i % 3 == 1:
        natija.append(str((ord(ch) * 2) % 10))
    else:
        natija.append(ch)
natija.append(str(len(harflar)))
print(''.join(natija))

Submit the answer in the form BAYROQ{M1X_PY_<natija>} — the printed string result itself.

Hints 2
Opening a hint reduces the points you get for solving this challenge.
Hint 1 −1 pts Log in
Hint 2 −3 pts Log in
To submit a flag, log in.

First solvers

1. BlackCipher 03.10.2026
2. Лазиз 04.10.2026
3. Mirjaxon Qaxxarov 28.10.2026
4. Odam 06.11.2026
5. Doston Allayarov 12.11.2026
6. Maftuna 13.11.2026
7. jasmina_05 16.11.2026
8. Azizjon_20061609 19.11.2026
9. Adam Mahmoud 25.11.2026
10. Asmaa Mottery 25.11.2026