Search Results

Showing results 1 to 40 of 122
Search took 0.02 seconds.
Search: Posts Made By: tux4life
Forum: PHP Oct 21st, 2009
Replies: 6
Views: 427
Posted By tux4life
I don't know whether it's the only thing, but look very closely at this:

$tens = array(
1 => 'Ten',
2 => 'Twenty',
3 => 'Thirty',
4 => 'Fourty',
5 => 'Fifty',
6 => 'Sixty',
7 =>...
Forum: C Oct 20th, 2009
Replies: 4
Views: 371
Posted By tux4life
What exactly is the purpose of your code?
To me it seems like you're reading a file character by character, and then printing out only the digits?

Why doing a conversion to integer if you only...
Forum: C++ Oct 19th, 2009
Replies: 5
Views: 309
Posted By tux4life
The constructor is called when (= at the time) an object of a class is created.
The object's destructor is called at the time the object is destructed.
When you've manually allocated memory inside...
Forum: C Oct 19th, 2009
Replies: 12
Views: 521
Posted By tux4life
You can always put the call to printf in an if-statement, like this:

#include <stdio.h>

int main(void)
{
if( printf("Hello World!\n") ) {}
return 0;
}
As you can see, no semicolon...
Forum: Geeks' Lounge Oct 16th, 2009
Replies: 179
Views: 10,794
Posted By tux4life
Well, that's because I was not aware of the fact that I'd be a Linux island in a sea of Windows users at the time I chose my alias :P
You have to understand that my brothers and I share one computer...
Forum: Geeks' Lounge Oct 16th, 2009
Replies: 179
Views: 10,794
Posted By tux4life
I'm only going to say one thing:
That's maybe a reason for anyone out here to stop arguing.
Even when you continue arguing for a century or longer, people will always have different opinions and...
Forum: C++ Oct 13th, 2009
Replies: 6
Views: 681
Posted By tux4life
No offense, but I'm not an "avaricious" person like others, I'll do it for only $500 :P
(that's 200 times cheaper than Ancient Dragon's offer :))
Forum: C++ Oct 10th, 2009
Replies: 7
Views: 509
Posted By tux4life
http://www.gidnetwork.com/b-61.html
Forum: Geeks' Lounge Oct 9th, 2009
Replies: 179
Views: 10,794
Posted By tux4life
I said free licenses, not free computers.

You really aren't going to convince me (and probably the other people as well) as long as something very worse happens to me as a result of using Windows.
Forum: Geeks' Lounge Oct 8th, 2009
Replies: 179
Views: 10,794
Posted By tux4life
To answer the question "Why would everyone use Windows?":

Maybe because it's delivered by default if you buy a new computer? (OEM)
Maybe because Microsoft gives away free licenses of their...
Forum: Geeks' Lounge Oct 8th, 2009
Replies: 179
Views: 10,794
Posted By tux4life
Why using DirectX? Weren't you an Anti-Microsoft person?
Now it's really becoming curious.
Forum: Geeks' Lounge Oct 8th, 2009
Replies: 179
Views: 10,794
Posted By tux4life
Well, if we're going to start about nicknames: the mad in your nickname exactly fits with your attitude.
Forum: C Oct 5th, 2009
Replies: 9
Views: 852
Posted By tux4life
I've to admit that the union approach was just a bad and clunky advice.
But I just can't get this:
Why would someone use an unportable function to do the job when there's a portable function which...
Forum: C Oct 4th, 2009
Replies: 5
Views: 7,089
Posted By tux4life
>use fgets() instead of scanf() because it avoids buffer overflow problems if you type in more characters than name will hold.
I'm not going to repeat what Tom Gunn said once, I'm just going to link...
Forum: C Oct 2nd, 2009
Replies: 2
Views: 252
Posted By tux4life
And...why do I have to do this when the assignment has been given to you?
I suggest you to have a nice read: http://www.daniweb.com/forums/announcement8-2.html :)
Come back when you've something to...
Forum: C Oct 1st, 2009
Replies: 5
Views: 575
Posted By tux4life
As the title says: a C function for detecting anagrams.
Returns true if both strings are anagrams, returns false otherwise.
Forum: C Sep 21st, 2009
Replies: 17
Views: 1,572
Posted By tux4life
This code is wrong when you want to display the size of a char (in bits):

printf("Size of char: %d-bits\n", sizeof(char)*4);
Sure it will report that a char variable consists out of 4 bits, but...
Forum: C++ Sep 20th, 2009
Replies: 6
Views: 1,583
Posted By tux4life
I already know this kind of game: we make suggestions and never it's a good suggestion because either it's too difficult, or too easy, or too boring, or whatever else.

You know what you can and...
Forum: C Sep 20th, 2009
Replies: 2
Views: 417
Posted By tux4life
In addition (personally one of my favourite links):
http://cboard.cprogramming.com/c-programming/88495-development-process.html
Forum: C++ Sep 19th, 2009
Replies: 8
Views: 602
Posted By tux4life
Post down your code please.
Forum: Java Sep 15th, 2009
Replies: 5
Views: 741
Posted By tux4life
Seems like I have a lot more luck than you:
http://www.janiry.com/bruce-eckel/

(the Java e-book is for and older Java version, 1.4 I believe, but is still useful)
Have success reading them :P
Forum: C++ Sep 12th, 2009
Replies: 36
Views: 1,452
Posted By tux4life
Okay, I really have enough of your double postings in your thread:

a) you won't get help faster by doing this
b) you just make your own thread unreadable
c) you waste your time, use that time to...
Forum: C Sep 12th, 2009
Replies: 12
Views: 1,032
Posted By tux4life
Using a 'normal' array this isn't possible in C, you could maybe try your hands on a linked list (http://www.eternallyconfuzzled.com/tuts/datastructures/jsw_tut_linklist.aspx)?
Forum: C++ Sep 8th, 2009
Replies: 36
Views: 1,452
Posted By tux4life
First of all I want you to NOT PM me with your questions to do it for you, it won't work, I'm a free person and I'm free to do what I want, and not to do what I don't want (let that be clear).
What...
Forum: C++ Sep 6th, 2009
Replies: 7
Views: 740
Posted By tux4life
The part on how to fix it:
I see you want to compare a string-variable with a string literal, but you're doing something wrong: you're using the =-operator, this operator is also called the...
Forum: C++ Sep 5th, 2009
Replies: 17
Views: 757
Posted By tux4life
To the OP:
No offense, but I can't trust the code you posted down.
Wait, let me explain, I came across a line which looked quite strange to me, and which will never let me compile this program:...
Forum: Java Aug 29th, 2009
Replies: 7
Views: 423
Posted By tux4life
I wouldn't complain when developing in Java takes longer, as long as I get paid per hour :P
Forum: C++ Aug 29th, 2009
Replies: 35
Views: 1,667
Posted By tux4life
Yep, if you use bitwise AND, then only if the two corresponding bits are one, then the bit in the outcome is also one, otherwise it is always zero (you can derive this rule from that truth table).
...
Forum: C Aug 28th, 2009
Replies: 8
Views: 497
Posted By tux4life
>Got exam tomorrow
Cool! I've exams too within 3-and-a-half months, wish me the best :P.

>Erm, such like syntax error that kind, got what other type of error else?
So, if I don't misunderstand...
Forum: C++ Aug 26th, 2009
Replies: 35
Views: 1,667
Posted By tux4life
Not always necessary, but in this case it seems most appropriate.
Just take the way which is easiest for you, and in most cases, it's directly inputting the value.
(If the value is in another base...
Forum: C++ Aug 25th, 2009
Replies: 2
Views: 298
Posted By tux4life
NOTE: Throughout my whole post I assume that bytes consist out of eight bits.

When you use the XOR-algorithm to hash/encrypt your data, there's no need to implement a different way to decrypt your...
Forum: C Aug 24th, 2009
Replies: 4
Views: 508
Posted By tux4life
Wait, I doubt whether this program will correctly terminate on every machine, it appears that it won't, because you're using void main(), the standard says that you must use int main() and not void...
Forum: C Aug 24th, 2009
Replies: 6
Views: 416
Posted By tux4life
Here's something essential, start from this and write the rest on your own:
#include <stdio.h>

/*
Your function declarations
*/

int main(void)
{
/*
Forum: C Aug 21st, 2009
Replies: 2
Views: 288
Posted By tux4life
I guess he's using Turbo Crap v3.0 :P

Could you provide us:

The program which you did try to compile.
The complete linker error message.
Forum: C++ Aug 21st, 2009
Replies: 11
Views: 892
Posted By tux4life
Actually, an array is a list/set of variables, for example:

int array[15];
The above array reserves memory for 15 elements (of type int) (as all arrays start with element 0, the upperbound of...
Forum: C++ Aug 15th, 2009
Replies: 1
Views: 253
Posted By tux4life
-> is called the arrow operator and is often used to access the data members of a structure (via a pointer).
Consider a structure which looks like this:

struct dog
{
string name;
int age;...
Forum: C++ Aug 15th, 2009
Replies: 19
Views: 736
Posted By tux4life
Hmm, smells like you need a structure (often abbreviated as: struct).
structs are used to group related variables into a new user-defined type, let me give you an example, you want to store the...
Forum: C Jul 30th, 2009
Replies: 17
Views: 657
Posted By tux4life
@RobBrown:
>was rather unhelpful, and honestly not very bright...

I'm very sorry that my eyes aren't good enough to see the error messages on your computer's monitor.
Do you maybe expect that...
Forum: Java Jul 29th, 2009
Replies: 4
Views: 225
Posted By tux4life
Do you imply that I have to write the program?
There's one obstacle in your way:
We only give homework help to those who show effort! (http://www.daniweb.com/forums/announcement8-2.html)
So please...
Forum: C Jul 29th, 2009
Replies: 8
Views: 296
Posted By tux4life
Nope, not a joke.
It's just: most of the time the word 'byte' is interpreted as an octet of bits (8 bits), but this is not fully correct, as a byte is an abstract term for the smallest addressable...
Showing results 1 to 40 of 122

 


About Us | Contact Us | Advertise | DaniWeb | Acceptable Use Policy | RSS Feed

©2003 - 2009 DaniWeb® LLC