Post History
Python 2, 76 bytes i=27 while~i:print' '*i+' '.join(`min(i,j,27-i-j)`for j in range(28-i));i-=1 Try it online! Computes the digit in row i from the bottom, position j as min(i,j,27-i-j). F...
Answer
#6: Post edited
- # [Python 2], 76 bytes
- <!-- language-all: lang-python -->
- i=27
- while~i:print' '*i+' '.join(`min(i,j,27-i-j)`for j in range(28-i));i-=1
- [Try it online!][TIO-khh8qgcy]
- [Python 2]: https://docs.python.org/2/
- [TIO-khh8qgcy]: https://tio.run/##DcSxCoAgFAXQva9wSyuDXIyif6nB6ko9RYRo6ddfnuHEN5@BDDMWY6vnxOU@TDGBci3qBm259wEk17uEznfGamiv1j0k4QVIpI0OJ82oodQMvQzMPw "Python 2 – Try It Online"
Computes the digit in row `i`, position `j` as `min(i,j,27-i-j)`.- For comparison, a bad effect to compute the row numbers arithmetically, made harder by the presence of leading zeroes:
- **109 bytes**
- <!-- language-all: lang-python -->
- for i in range(28):print" "*(27-i)+" ".join(str(10**min(27-i,i/2)/9*(10**max(2*i-27,-~i/2)/9)*10).zfill(i+1))
- [Try it online!][TIO-khh9drk9]
- [Python 2]: https://docs.python.org/2/
- [TIO-khh9drk9]: https://tio.run/##JckxEoIwEEbhq2SodhcCZBvU21AI/A5umJgCLbx6xKH75r3tnZdoWsoUk4ODuTTafCe98G1LsFy5SkgHD64Pto8Io1dOFHqR5@H/atApd1c547iTCrwOjf@egyX03H4mrCuhDsyl/AA "Python 2 – Try It Online"
- # [Python 2], 76 bytes
- <!-- language-all: lang-python -->
- i=27
- while~i:print' '*i+' '.join(`min(i,j,27-i-j)`for j in range(28-i));i-=1
- [Try it online!][TIO-khh8qgcy]
- [Python 2]: https://docs.python.org/2/
- [TIO-khh8qgcy]: https://tio.run/##DcSxCoAgFAXQva9wSyuDXIyif6nB6ko9RYRo6ddfnuHEN5@BDDMWY6vnxOU@TDGBci3qBm259wEk17uEznfGamiv1j0k4QVIpI0OJ82oodQMvQzMPw "Python 2 – Try It Online"
- Computes the digit in row `i` from the bottom, position `j` as `min(i,j,27-i-j)`.
- For comparison, a bad effect to compute the row numbers arithmetically, made harder by the presence of leading zeroes:
- **109 bytes**
- <!-- language-all: lang-python -->
- for i in range(28):print" "*(27-i)+" ".join(str(10**min(27-i,i/2)/9*(10**max(2*i-27,-~i/2)/9)*10).zfill(i+1))
- [Try it online!][TIO-khh9drk9]
- [Python 2]: https://docs.python.org/2/
- [TIO-khh9drk9]: https://tio.run/##JckxEoIwEEbhq2SodhcCZBvU21AI/A5umJgCLbx6xKH75r3tnZdoWsoUk4ODuTTafCe98G1LsFy5SkgHD64Pto8Io1dOFHqR5@H/atApd1c547iTCrwOjf@egyX03H4mrCuhDsyl/AA "Python 2 – Try It Online"
#5: Post edited
- # [Python 2], 76 bytes
- <!-- language-all: lang-python -->
- i=27
- while~i:print' '*i+' '.join(`min(i,j,27-i-j)`for j in range(28-i));i-=1
- [Try it online!][TIO-khh8qgcy]
- [Python 2]: https://docs.python.org/2/
- [TIO-khh8qgcy]: https://tio.run/##DcSxCoAgFAXQva9wSyuDXIyif6nB6ko9RYRo6ddfnuHEN5@BDDMWY6vnxOU@TDGBci3qBm259wEk17uEznfGamiv1j0k4QVIpI0OJ82oodQMvQzMPw "Python 2 – Try It Online"
- Computes the digit in row `i`, position `j` as `min(i,j,27-i-j)`.
For comparison, a bad effect to compute the row numbers arithmetically, made harder by the presence of zeroes.- **109 bytes**
- <!-- language-all: lang-python -->
- for i in range(28):print" "*(27-i)+" ".join(str(10**min(27-i,i/2)/9*(10**max(2*i-27,-~i/2)/9)*10).zfill(i+1))
- [Try it online!][TIO-khh9drk9]
- [Python 2]: https://docs.python.org/2/
- [TIO-khh9drk9]: https://tio.run/##JckxEoIwEEbhq2SodhcCZBvU21AI/A5umJgCLbx6xKH75r3tnZdoWsoUk4ODuTTafCe98G1LsFy5SkgHD64Pto8Io1dOFHqR5@H/atApd1c547iTCrwOjf@egyX03H4mrCuhDsyl/AA "Python 2 – Try It Online"
- # [Python 2], 76 bytes
- <!-- language-all: lang-python -->
- i=27
- while~i:print' '*i+' '.join(`min(i,j,27-i-j)`for j in range(28-i));i-=1
- [Try it online!][TIO-khh8qgcy]
- [Python 2]: https://docs.python.org/2/
- [TIO-khh8qgcy]: https://tio.run/##DcSxCoAgFAXQva9wSyuDXIyif6nB6ko9RYRo6ddfnuHEN5@BDDMWY6vnxOU@TDGBci3qBm259wEk17uEznfGamiv1j0k4QVIpI0OJ82oodQMvQzMPw "Python 2 – Try It Online"
- Computes the digit in row `i`, position `j` as `min(i,j,27-i-j)`.
- For comparison, a bad effect to compute the row numbers arithmetically, made harder by the presence of leading zeroes:
- **109 bytes**
- <!-- language-all: lang-python -->
- for i in range(28):print" "*(27-i)+" ".join(str(10**min(27-i,i/2)/9*(10**max(2*i-27,-~i/2)/9)*10).zfill(i+1))
- [Try it online!][TIO-khh9drk9]
- [Python 2]: https://docs.python.org/2/
- [TIO-khh9drk9]: https://tio.run/##JckxEoIwEEbhq2SodhcCZBvU21AI/A5umJgCLbx6xKH75r3tnZdoWsoUk4ODuTTafCe98G1LsFy5SkgHD64Pto8Io1dOFHqR5@H/atApd1c547iTCrwOjf@egyX03H4mrCuhDsyl/AA "Python 2 – Try It Online"
#4: Post edited
- # [Python 2], 76 bytes
- <!-- language-all: lang-python -->
- i=27
- while~i:print' '*i+' '.join(`min(i,j,27-i-j)`for j in range(28-i));i-=1
- [Try it online!][TIO-khh8qgcy]
- [Python 2]: https://docs.python.org/2/
- [TIO-khh8qgcy]: https://tio.run/##DcSxCoAgFAXQva9wSyuDXIyif6nB6ko9RYRo6ddfnuHEN5@BDDMWY6vnxOU@TDGBci3qBm259wEk17uEznfGamiv1j0k4QVIpI0OJ82oodQMvQzMPw "Python 2 – Try It Online"
- For comparison, a bad effect to compute the row numbers arithmetically, made harder by the presence of zeroes.
- **109 bytes**
- <!-- language-all: lang-python -->
- for i in range(28):print" "*(27-i)+" ".join(str(10**min(27-i,i/2)/9*(10**max(2*i-27,-~i/2)/9)*10).zfill(i+1))
- [Try it online!][TIO-khh9drk9]
- [Python 2]: https://docs.python.org/2/
- [TIO-khh9drk9]: https://tio.run/##JckxEoIwEEbhq2SodhcCZBvU21AI/A5umJgCLbx6xKH75r3tnZdoWsoUk4ODuTTafCe98G1LsFy5SkgHD64Pto8Io1dOFHqR5@H/atApd1c547iTCrwOjf@egyX03H4mrCuhDsyl/AA "Python 2 – Try It Online"
- # [Python 2], 76 bytes
- <!-- language-all: lang-python -->
- i=27
- while~i:print' '*i+' '.join(`min(i,j,27-i-j)`for j in range(28-i));i-=1
- [Try it online!][TIO-khh8qgcy]
- [Python 2]: https://docs.python.org/2/
- [TIO-khh8qgcy]: https://tio.run/##DcSxCoAgFAXQva9wSyuDXIyif6nB6ko9RYRo6ddfnuHEN5@BDDMWY6vnxOU@TDGBci3qBm259wEk17uEznfGamiv1j0k4QVIpI0OJ82oodQMvQzMPw "Python 2 – Try It Online"
- Computes the digit in row `i`, position `j` as `min(i,j,27-i-j)`.
- For comparison, a bad effect to compute the row numbers arithmetically, made harder by the presence of zeroes.
- **109 bytes**
- <!-- language-all: lang-python -->
- for i in range(28):print" "*(27-i)+" ".join(str(10**min(27-i,i/2)/9*(10**max(2*i-27,-~i/2)/9)*10).zfill(i+1))
- [Try it online!][TIO-khh9drk9]
- [Python 2]: https://docs.python.org/2/
- [TIO-khh9drk9]: https://tio.run/##JckxEoIwEEbhq2SodhcCZBvU21AI/A5umJgCLbx6xKH75r3tnZdoWsoUk4ODuTTafCe98G1LsFy5SkgHD64Pto8Io1dOFHqR5@H/atApd1c547iTCrwOjf@egyX03H4mrCuhDsyl/AA "Python 2 – Try It Online"
#3: Post edited
- # [Python 2], 76 bytes
- <!-- language-all: lang-python -->
- i=27
- while~i:print' '*i+' '.join(`min(i,j,27-i-j)`for j in range(28-i));i-=1
- [Try it online!][TIO-khh8qgcy]
- [Python 2]: https://docs.python.org/2/
[TIO-khh8qgcy]: https://tio.run/##DcSxCoAgFAXQva9wSyuDXIyif6nB6ko9RYRo6ddfnuHEN5@BDDMWY6vnxOU@TDGBci3qBm259wEk17uEznfGamiv1j0k4QVIpI0OJ82oodQMvQzMPw "Python 2 – Try It Online"
- # [Python 2], 76 bytes
- <!-- language-all: lang-python -->
- i=27
- while~i:print' '*i+' '.join(`min(i,j,27-i-j)`for j in range(28-i));i-=1
- [Try it online!][TIO-khh8qgcy]
- [Python 2]: https://docs.python.org/2/
- [TIO-khh8qgcy]: https://tio.run/##DcSxCoAgFAXQva9wSyuDXIyif6nB6ko9RYRo6ddfnuHEN5@BDDMWY6vnxOU@TDGBci3qBm259wEk17uEznfGamiv1j0k4QVIpI0OJ82oodQMvQzMPw "Python 2 – Try It Online"
- For comparison, a bad effect to compute the row numbers arithmetically, made harder by the presence of zeroes.
- **109 bytes**
- <!-- language-all: lang-python -->
- for i in range(28):print" "*(27-i)+" ".join(str(10**min(27-i,i/2)/9*(10**max(2*i-27,-~i/2)/9)*10).zfill(i+1))
- [Try it online!][TIO-khh9drk9]
- [Python 2]: https://docs.python.org/2/
- [TIO-khh9drk9]: https://tio.run/##JckxEoIwEEbhq2SodhcCZBvU21AI/A5umJgCLbx6xKH75r3tnZdoWsoUk4ODuTTafCe98G1LsFy5SkgHD64Pto8Io1dOFHqR5@H/atApd1c547iTCrwOjf@egyX03H4mrCuhDsyl/AA "Python 2 – Try It Online"
#2: Post edited
- # [Python 2], 76 bytes
- <!-- language-all: lang-python -->
i=26while~i:print' '*i+' '.join(`min(i,j,26-i-j)`for j in range(27-i));i-=1[Try it online!][TIO-khh8ohqk]- [Python 2]: https://docs.python.org/2/
[TIO-khh8ohqk]: https://tio.run/##DcSxCoAgFAXQva9wSyuDHAyK/qUGqyv1FBGipV9/eYYT33wGMsxYjK2eE5f7MMUEyrWoG7Tl3geQXO8SOt8Zq6G9WveQhBcgkTY6nDSjhlIz9DIw/w "Python 2 – Try It Online"
- # [Python 2], 76 bytes
- <!-- language-all: lang-python -->
- i=27
- while~i:print' '*i+' '.join(`min(i,j,27-i-j)`for j in range(28-i));i-=1
- [Try it online!][TIO-khh8qgcy]
- [Python 2]: https://docs.python.org/2/
- [TIO-khh8qgcy]: https://tio.run/##DcSxCoAgFAXQva9wSyuDXIyif6nB6ko9RYRo6ddfnuHEN5@BDDMWY6vnxOU@TDGBci3qBm259wEk17uEznfGamiv1j0k4QVIpI0OJ82oodQMvQzMPw "Python 2 – Try It Online"
#1: Initial revision
# [Python 2], 76 bytes <!-- language-all: lang-python --> i=26 while~i:print' '*i+' '.join(`min(i,j,26-i-j)`for j in range(27-i));i-=1 [Try it online!][TIO-khh8ohqk] [Python 2]: https://docs.python.org/2/ [TIO-khh8ohqk]: https://tio.run/##DcSxCoAgFAXQva9wSyuDHAyK/qUGqyv1FBGipV9/eYYT33wGMsxYjK2eE5f7MMUEyrWoG7Tl3geQXO8SOt8Zq6G9WveQhBcgkTY6nDSjhlIz9DIw/w "Python 2 – Try It Online"