Nested For Loops

Hi i need to write a code that creates a certain pattern

X
X X
XX X
XX X
XXX X
XXX X
XXX X
XXXX X
XXXX X
XXXX X
XXXX X

Thanks in Advance
fou could use a for() function to do that
A for loop with a switch case would be useful for you. If you want your code to look really good, use a for loop in a for loop: the outer would increment a value i which would be passed somehow to the inner for loop which would print your pattern.

-Albatross
Topic archived. No new replies allowed.