Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save timotheecour/e418ea55670b57c325da98a996ff9527 to your computer and use it in GitHub Desktop.
Save timotheecour/e418ea55670b57c325da98a996ff9527 to your computer and use it in GitHub Desktop.
```
when defined case11: # D20210513T184020:here
import math,strformat
echo " in | cm"
echo "---------------------"
for i in 1 .. 40:
echo fmt"{i:3}", " | ", round(float(i) * 2.54, 2)
```
after PR:
in | cm
---------------------
1 | 2.54
2 | 5.08
3 | 7.62
4 | 10.16
5 | 12.7
6 | 15.24
7 | 17.78
8 | 20.32
9 | 22.86
10 | 25.4
11 | 27.94
12 | 30.48
13 | 33.02
14 | 35.56
15 | 38.1
16 | 40.64
17 | 43.18
18 | 45.72
19 | 48.26
20 | 50.8
21 | 53.34
22 | 55.88
23 | 58.42
24 | 60.96
25 | 63.5
26 | 66.04
27 | 68.58
28 | 71.12
29 | 73.66
30 | 76.2
31 | 78.74
32 | 81.28
33 | 83.82
34 | 86.36
35 | 88.9
36 | 91.44
37 | 93.98
38 | 96.52
39 | 99.06
40 | 101.6
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment