Latest web development tutorials

Python beinhaltet 81 Übungen

Python 100 Li Python 100 Li

Titel: 809 * 800 * ?? = ?? zweistelligen + 9 + 1 * ?? ?? , die 8 dargestellt * ?? Ergebnis der zweistelligen, 9 * ?? ergibt 3 Ziffern. ?? Die Vertreter der Suche nach einem zweistelligen, und die Ergebnisse nach 809 * ??.

Programmanalyse: Keine.

Source Code:

#!/usr/bin/python
# -*- coding: UTF-8 -*-

a = 809
for i in range(10,100):
    b = i * a + 1
    if b >= 1000 and b <= 10000 and 8 * i < 100 and 9 * i >= 100:
        print b,'/',i,' = 809 * ',i,' + ', b % i

Das obige Beispiel Ausgabe lautet:

9709 / 12  = 809 *  12  +  1

Python 100 Li Python 100 Li