Tools

Brainfuck String Generator Generator

Here is a small C program, which takes a string as its input, and generates a (not so trivial) brainfuck code which generates this string.
For a tool to convert brainfuck code into C, see this post

To run the program, first compile it with gcc:

gcc -o bf_generator bf_generator.c

No, run it:

./bf_generator “a string to convert into brainfuck code”

You can also pass a text file as its input through a pipe:

cat testfile.txt | ./bf_generator

Download the source code here: Brainfuck Generator Generator 2.41 KB

Enjoy ;)

Post to Twitter Post to Delicious Post to Digg Post to Facebook Post to Reddit Post to StumbleUpon

Tags: ,

Thursday, June 18th, 2009 Tools 1 Comment

A Program for Bit-Slicing

I wrote this short program in C because I needed to do some bit-slicing in some homework. It's not too generic (accepts only 32 bit integers) but it can help in most cases.


An example usage of the program:

bs 0x12345678 31 4


Will give the following output:

0x12345678[31:4] = 0x1234567

› Continue reading

Post to Twitter Post to Delicious Post to Digg Post to Facebook Post to Reddit Post to StumbleUpon

Tags: ,

Wednesday, June 10th, 2009 Tools 1 Comment
my email
my photo
Hi,
My name is Amir Watad. I have a BSc. in biomedical engineering from The Biomedical Engineering school , Technion , Israel, and a BSc. in electrical engineering from The Electrical Engineering school , Technion , Israel.
I'm a Verification Engineer in Mellanox Technologies Ltd.
I love Linux, the Command Line and the OpenSource Community.
I used to write Poems (Arabic) when I was able to find time for this.
September 2010
S M T W T F S
« Aug    
 1234
567891011
12131415161718
19202122232425
2627282930  
SEO Powered by Platinum SEO from Techblissonline

Twitter links powered by Tweet This v1.6.1, a WordPress plugin for Twitter.