560 Posted Topics
I'm trying to make a simple prime number generator for bigger program. It needs two numbers (n and c) and needs to edit them. So I decided to put the numbers in pointers, and just give the adress two the pointers. After about a half-houre of fumbling with *'s and … | |
Lately, I've been looking into cryptography, and I'm seeing if I can make a fun, maybe half-decent symetrical encryption alorithm. I am no professional, I've just seen a few algorithms online. I've came up with a few ideas: Version 1) I started of with simple xor encryption. I've learned that … | |
I'm trying to solve [URL="http://code.google.com/codejam/contest/dashboard?c=agdjb2RlamFtcg4LEghjb250ZXN0cxh5DA"]this[/URL] problem. The input file I used was the one on the site: [CODE]4 9 0123456789 oF8 Foo oF8 0123456789 13 0123456789abcdef 01 CODE O!CDE? A?JM!.[/CODE] My abstract idea was: Read the first line, loop the program that many times. Read the next line. Load the … | |
Re: Are you trying to make a shell that will run ontop of windows executing windows/dos programs? Just keep track of your current directory youself in an extra variable. Example: [CODE]cd c:\myprogram[/CODE] The current directory variable now holds: c:\myprogram\ (remember to check if it exsists) [CODE]main[/CODE] Would first check to see … | |
Re: Can you refraise your question? Sounds like this is a puzzle of some sort. | |
I just wrote a simple function to convert a number with any base into a base 10 number: [CODE=c]#include <stdio.h> #include <math.h> #include <string.h> int tobase10(int *input, int size, int base); int main() { int input[256] = {2, 2, 1, 0}; printf("%d\n", tobase10(input, 4, 3)); printf("Press any key to continue … | |
Re: LAME. [URL="http://lame.sourceforge.net/index.php"]Click here[/URL] | |
Here's the deal. I have two arrays. One defining a character set(could be any length), and another defining a string. I want to switch every letter in the string with its placement on the character set. For example: chrset[256] = "abcdefg" string[256] = "gfdc" will turn into: chrset[256] = "abcdefg" … | |
Just getting back into c (I've been dosing assembly for the last few months), so don't laugh at me :S I'm trying to read an input file. The fist line contains how many lines to read. The rest of the lines contain 3 words. Here's an example: [CODE]3 Hello, World … | |
Hey I'm learning assembly (low level only for now) on my linuxbox. Could someone convert the following c++ to asm(low level) so i can learn how to do math operations? #include <iostream> using namespace std; int main() { int a = 10; int b = 12; cout<<a+b<<endl; } Of course … |
The End.