in reply to Need help converting!!!
- Use a shebang line at the top of your program, usually followed by strict and warnings.
- Use print to display text to the user.
- Use the diamond operator (readline) to read the input.
- Use if and comparison operators.
- A block starts with a {.
- Use + for addition.
- Use ++ to increment.
- Use == to test numeric equality.
- Use = for assignment.
- -
- > is an operator.
- < is an operator, too.
- Rather than using goto, wrap the whole part in a while loop.
- Use + for addition.
- The while condition should test whether the loop should end or not. You'll have to adjust the algorithm a bit, as you can't test before you get the input, but the test is the first thing in the loop (or last, see do).
- A block starts with a {.
- / is the division operator .
- Use print again.
- Perl terminates once it has no more lines to execute.
($q=q:Sq=~/;[c](.)(.)/;chr(-||-|5+lengthSq)`"S|oS2"`map{chr |+ord }map{substrSq`S_+|`|}3E|-|`7**2-3:)=~y+S|`+$1,++print+eval$q,q,a,
|
---|
Replies are listed 'Best First'. | |
---|---|
Re^2: Need help converting!!!
by tonto (Friar) on Nov 15, 2015 at 23:53 UTC | |
Re^2: Need help converting!!!
by james28909 (Deacon) on Nov 16, 2015 at 02:18 UTC | |
by LanX (Saint) on Nov 16, 2015 at 02:48 UTC | |
by james28909 (Deacon) on Nov 16, 2015 at 04:32 UTC | |
by Preceptor (Deacon) on Nov 16, 2015 at 17:29 UTC | |
by LanX (Saint) on Nov 16, 2015 at 17:53 UTC | |
by afoken (Chancellor) on Nov 17, 2015 at 05:38 UTC | |
by dsheroh (Monsignor) on Nov 16, 2015 at 08:35 UTC |
In Section
Seekers of Perl Wisdom