import random
def DEF(A,B,C):
    if B > 0:
        print("")
        for _ in range(A):
            print('DEF',end="")
        DEF(A+1,B-1,C)
    
    if C > 0:
        print("")
        DEF(B,A,C-1)  
DEF(0,3,3)

Embed on website

To embed this project on your website, copy the following code and paste it into your website's HTML: