I use TinyPerl 5.8 on Windows XP. Unfortunately, many of the modules are not working on my computer, so I write my own sub-routines. I use this Perl "toolbox" file to grab what I need.
If you trade stocks, you will have to report your sales to the IRS. During tax season, Robinhood's platform allows you to download the trades in PDF form. Most PDF viewers allow you to convert the PDF to TXT. And this Perl script will convert the TXT to CSV so you can import it into Excel. If you make a lot of trades, this tool comes handy. It can save you days of tedious work and do it in 5 seconds. This program can also be useful for accountants who have to enter a lot of Robinhood trades. This tool makes it super fast to process a large number of trades. The output will show the security name, number of shares, date acquired, date sold, profit or loss, cost basis, wash sale, etc.
This program is the same as the one above, but this works for 1099 tax PDF files released by Charles Schwab brokerage firm. This program takes TXT files and converts them to CSV.
This ZIP file contains Notepad2, TinyPerl 5.8 for Windows (executable) and Robinhood.pl and Schwab.pl. It's 12 megabytes. This is all you need to run my perl scripts. Expand to a folder called C:\PERL and follow the instructions in README.TXT. (Note: Perl was invented by Larry Wall, and TinyPerl was built by Graciliano M. P. in 2003. Notepad2 was created by Florian Balmer.)
This perl script compares two directories. It compares directory1 and directory2, and displays a list of files and directories that do not exist in directory2.
KNAPSACK1.PL and KNAPSACK2.PL
This script solves the knapsack problem. The knapsack problem goes something like this: You have 100 items each with different size. And you have a bag which you must fill all the way to the top. You have to figure out how to fill the bag in a way that you end up with the least amount of empty space. This script tries to find a combination of numbers whose sum equals 500. The random numbers are between 1 and 500.
The first script solves the problem step by step, displaying what happens at each step. The second script just solves the problem and displays the results without "debug" messages.
This tiny script was a programming exercise I saw somewhere. It sorts email addresses by domain.
This Perl script deletes duplicate JPG files within a directory. Sounds like a great idea at first, but it's not. If I have 3 identical JPG files called "Charles.jpg" and "Copy of Charles.jpg" and "Florida.jpg" then I want to keep the first one, but the program doesn't know how to come to that decision. So, it will ask the user each time what to do. This makes the program really slow. If you have thousands of duplicate files, it will take forever...
This Perl script demonstrates the QuickSort algorithm. This program sorts an array of numbers.
Displays the contents of a directory.
Analyzes file contents and displays what percentage of a file is binary vs plain text.
This script converts all Linux/Apple text files in the current directory to DOS format.
This function converts any binary string to plain text format that contains nothing but letters and numbers. The algorithm tries to compress the string by using a simple RLE algorithm and grouping characters depending on how often they are used. So, in some cases, the output will be shorter than the input. Most of the time the result will be smaller than what we can achieve using the escape() function or string2hex() function or base64 encoding.
This script displays the prime numbers under 1 million, and it contains functions for factoring numbers and finding the common factor.
This script calculates the first 15 digits of PI using the BBP formula which was discovered in 1995 by Canadian mathematician Simon Plouffe.