diff options
| author | Reiner Herrmann <reiner@reiner-h.de> | 2014-08-31 20:21:45 +0200 |
|---|---|---|
| committer | Reiner Herrmann <reiner@reiner-h.de> | 2014-08-31 20:35:09 +0200 |
| commit | 95341b61b030c9e1290f3b326cb7ec584f543aea (patch) | |
| tree | 852386fa04d32eb859bca11c0eff7b5ef9e50f00 /028.py | |
| parent | 571164d977f91925c4c76a292f74f5f93d09ae23 (diff) | |
Diffstat (limited to '028.py')
| -rw-r--r-- | 028.py | 13 |
1 files changed, 13 insertions, 0 deletions
@@ -0,0 +1,13 @@ + +width = 1001 +max_level = (width-1)/2 + +last = sum = 1 + +for level in range(1, max_level+1): + add = 2*level + sum += (last+add) + (last+2*add) + (last+3*add) + (last+4*add) + last = last+4*add + +print sum + |
