Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- @echo off
- :: Give it a tasteful look...
- color 0a
- :: Initial echos and setting of c value
- echo 1 1 1 1 1 1
- echo 1 1 1 1 1 1
- set /a a=1
- set /a b=1
- set /a c=%a%+%b%
- :: Time to loop, begin by echoing c then shifting all the values down
- :loop
- echo %c% %c% %c% %c% %c% %c%
- set /a a=%b%
- set /a b=%c%
- set /a c=%a%+%b%
- :: Check if c has overflowed the integer, reset to 1
- if %c% LSS 0 goto reset
- goto loop
- pause
- :: Actual code for resetting values
- :reset
- set /a a=1
- set /a b=1
- set /a c=1
- echo 1 1 1 1 1 1
- goto loop
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement