+ 1

Can we make it short?

I am a beginner.I tried writing my name in shortest code in python.If it can be made short further plz guide.cide: https://code.sololearn.com/cpk6QY7Ml5fN/?ref=app

5th Jul 2023, 1:08 PM
Tabish
Tabish - avatar
3 Réponses
+ 6
Tabish , all statements in the code given by SoloProg are in one line, separated by a semicolon. > since readability counts, this way of writing python code is *not recomnended*.
5th Jul 2023, 3:34 PM
Lothar
Lothar - avatar
+ 2
s,t,u,v,w,x=""," "," "," "," ",input("Enter symbol:") or "*";print() #2lines shortened
5th Jul 2023, 1:24 PM
SoloProg
SoloProg - avatar
+ 1
3 lines of unreadability... x=input("Enter symbol:\n")or"*" a,b,c,d,n,s,t,u,v,w=3*x,4*x,5*x,6*x,"\n",""," "," "," "," ", print(s,d,b,s,b,s,x,t,a,t,x,t,x,n,t,x,u,x,s,x,s,x,s,x,s,x,s,x,w,x,t,x,n,t,x,u,b,s,a,t,x,t,a,t,c,n,t,x,u,x,s,x,s,x,s,x,s,x,w,x,s,x,t,x,n,t,x,u,x,s,x,s,b,s,x,t,a,t,x,t,x)
6th Jul 2023, 11:16 AM
Bob_Li
Bob_Li - avatar