Jump to content
xisto Community
purifier

Printing Multiple Times Without Using Loops

Recommended Posts

Is it possible to print a number or a character a specified number of times without using any loops... or any conditional statements...? I tried my hand at it using recursion but even that requires a condition... tried using goto but that would be a loop and also requires a condition... I thought of a solution but it is a dumb one... don't take it too seriously... Use printf("CHARACTER"); 'n' times... :) Any ideas?

Share this post


Link to post
Share on other sites

You mean like PERL? 1 x 3 = 111 if I'm right... technically no because anything that you would do (besides create multiple copies of the command) would still tell the CPU to loop.

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

×
×
  • Create New...

Important Information

Terms of Use | Privacy Policy | Guidelines | We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.