Search found 6 matches

by 0xD34D
Mon Jul 14, 2014 4:41 am UTC
Forum: Coding
Topic: Project Euler
Replies: 411
Views: 151437

Re: Project Euler

Well, it is problem 1, after all. You're more learning how Project Euler itself works, rather than anything to do with the actual puzzle... the format they expect for the answers, how the site behaves when you put an answer in, that sort of thing. It's the PE version of a video game tutorial level....
by 0xD34D
Mon Jul 14, 2014 2:52 am UTC
Forum: Coding
Topic: Project Euler
Replies: 411
Views: 151437

Re: Project Euler

I haven't really gotten much into Project Euler yet, but is problem 1 (find the sum of multiples of 3 and 5 less that 1000) really just writing FizzBuzz with a painfully simple twist? I tried to write it like that, and did not even come to close to the answer. I don't have the code or anything...app...
by 0xD34D
Mon Jul 14, 2014 2:49 am UTC
Forum: Coding
Topic: Coding: Fleeting Thoughts
Replies: 9881
Views: 1799810

Re: Coding: Fleeting Thoughts

FT: I wish I knew some assembly things, and how to use gdb, but learning ASM is hell and I haven't found a tutorial on gdb. Can anyone suggest anything that will help me understand ASM in a way that might help me to write better C programs, since, after all, C is the main language I am trying to lea...
by 0xD34D
Fri Jul 11, 2014 5:27 pm UTC
Forum: Coding
Topic: Funniest/Most Annoying Code Comments
Replies: 662
Views: 135803

Re: Funniest/Most Annoying Code Comments

So I have been learning C from a book and I do remember reading that Linus Torvalds said "if you need more than 3 levels of nesting, you're screwed anyway." Here is a chunk of a program to find divisors. If you look on the first line, you can see my comment at the end. while(scanf("%l...
by 0xD34D
Fri Jul 11, 2014 5:20 pm UTC
Forum: Coding
Topic: The "IT DOESN'T WORK!" thread
Replies: 1958
Views: 518925

Re: The "IT DOESN'T WORK!" thread

It wouldn't compile for me because you're missing a semicolon in fib. Once I added the semicolon, it seemed to work correctly for me. Could you give a bit more detail about how it fails? Well, I'll try again with the semicolon that was apprently missing. I would type in a number [n] and it would ju...
by 0xD34D
Fri Jul 11, 2014 1:52 am UTC
Forum: Coding
Topic: The "IT DOESN'T WORK!" thread
Replies: 1958
Views: 518925

Re: The "IT DOESN'T WORK!" thread

Alright, so I am having a problem with something surprisingly simple...I can't figure out how to calculate a fibonacci sequence in C. I have the following code, but it either segfaults or returns random values. I feel like an absolute moron for not being able to get this to work. /*uses a loop funct...

Go to advanced search