Jump to content

Repeating commands?


Foxtrot

Recommended Posts

im not sure about infinite, but you can make it quite a few with a for loop

This *SHOULD* do the trick for you, just set the ending number to something unfathomable

0 is your starting number, 1000000 is your ending number, 1 is your iteration

#!/bin/bash
for i in {0..1000000..1}
  do
     echo "Hello World"
done

OR (This would be infinite, but not 100% certain if it would work right) lol

#!/bin/bash
while [ 1=1 ]
do
echo "Hello World!"
done
Edited by BlueWyvern
Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...