Skip to content
On this page

04_Loop_F06.py

WARNING

โค้ดกาวมากครับ อย่าลอกเลย 😭😭😭

ทำเองเถอะนะครับ จะได้ทำข้อสอบได้ 🥲🥲🥲

py
# pylint: disable=exec-used

# Thanks GitHub Copilot

def print_triangle(n):
    print(" " * (n - 1) + "*")
    for i in range(2, n):
        print(" " * (n - i) + "*" + " " * (2 * i - 3) + "*")
    print("*" * (2 * n - 1))


exec(input())

People who plagiarize Com Prog HW:

People who do Com Prog HW by themself:

Released under the MIT License