Skip to main content

5 replies

Aaron.Gleason
Automation Anywhere Team
Automation Anywhere Team
October 26, 2025

@rishav_anand Use Python. 

n = int(input("Enter a number: "))

for i in range(1, n + 1):
if i % 2 == 1: # Odd rows = numbers
for j in range(1, i + 1):
print(j, end=" ")
else: # Even rows = letters
for j in range(1, i + 1):
print(chr(64 + j), end=" ") # chr(65) is 'A'
print() # new line after each row

 

Cadet | Tier 2
October 29, 2025

@Aaron.Gleason thanks for the code but i want to print this with the help of automation anywhere without using python 

 

Aaron.Gleason
Automation Anywhere Team
Automation Anywhere Team
October 29, 2025

@rishav_anand Automation Anywhere is not a general programming language. It is a business automation language. As such, Python is a better language for this specific exercise. You can integrate Python directly into Automation Anywhere, and we frequently do for tasks such as yours that are more a programmer exercise than a business automation exercise. It’s a matter of using the right tool for the job.

That being said… it can be done…

 

Zaid Chougle
Navigator | Tier 3
Navigator | Tier 3
October 31, 2025

@rishav_anand Automation Anywhere is not a general programming language. It is a business automation language. As such, Python is a better language for this specific exercise. You can integrate Python directly into Automation Anywhere, and we frequently do for tasks such as yours that are more a programmer exercise than a business automation exercise. It’s a matter of using the right tool for the job.

That being said… it can be done…

 

WOAH! , that is some serious stuff ​@Aaron.Gleason 

Lets Automate !
Aaron.Gleason
Automation Anywhere Team
Automation Anywhere Team
October 31, 2025

@Zaid Chougle Thanks. There are some benefits to having 46 years of programming experience.  🤣

Just in case this is someone’s pre-hire exercise, I’m not going to explain some of the tricks I did here, but you might have noticed the Goto actions that I threw in just because.  😎