DOOOHHHH!!!!!! As homer would say!
indeed, i had forgotten to #include <iterator>
Type: Posts; User: fcommisso
DOOOHHHH!!!!!! As homer would say!
indeed, i had forgotten to #include <iterator>
this funciton initialized as:
void initCards(int *playerHand[], int *dealerHand[], int numOfCards)
is it wrong if I call it this way?
nvm, I see the problem now I posted it.... sorry guys.
OK take at look at this code. I've been starring for hours trying to decipher where I went wrong.
void initHandsToZero(int *playerHand[], int *dealerHand[]) {
int i;
for (i=0; i <...
ok, so then my next question is...
How can I have it spit out a random number from 1 to 52? both included...
will this code:
int randInt = rand() % 52;
ever hit the number 52??
ok. that ws horrible code. ignore that.
what will this do?
void fflushstdin( void )
{
int c;
ok.. sorry, but I still need more information. How can I implement it to my code?
void getBet(int* currentBet) {
int bet = 0;
for(printf("Enter Bet:\n"); 1; printSeparator()) {
Oh great links quzah! Thank you. I really didn't get how to do such a thing... shame that it isn't part of a library, uh?
nope.... unless i'm using it at the wrong time???
void getBet(int* currentBet) {
int bet = 0;
for(printf("Enter Bet:\n"); 1; printSeparator()) {
scanf("%d", &bet);
fflush(stdin);
i tried fflush(stdin);
but no luck
so I need to write a function clearBuffer() to clear the buffer after scanf...
anyone can give me any help??
I have no clue how to do this...i just know that i get a 'bus error' otherwise..
...
Hey, will this guarantee all the elements in my array will be declared zero? or should I got for a for loop instead?
int array[size] = {0};
How would I do that?
I need to read from a file and depending on some number calculation I can then declare the array's size.
I know static declaration is wrong...i wouldn't be able to use it in...
Thanks guys. And yes, I do know that decompiling my own executables isn't illegal, but if I hadn't written something of the like, I was sure to get someone rant to me about the illegality of reverse...
I know the title sounds more like an oxymoron than an actual problem, but I need help declaring an array that needs to be used in other functions inside a function that's first called in main.
So...
Hey, I'm looking into my old codes and I have what I remember to be my best programming project I coded in C for my C programming class last semester. The fact of the matter is that I seem to have...
here you go:
still doesn't fix it. maybe i need to declare a pointer that points to first and use that for the comparisons... ?
maybe something like
const struct Entry *p1
//. ... much codingz
I'm working on a function that finds entries in an address book given the linked list (first), the fieldId (i.e. a number form 1-7, such that 1 = First..name, 2 = Last..name, 3 = Street..address, 4 =...
hehe, that hint was too easy. I figured it out before you posted it, too! Thanks a lot.
Ok, thanks. I still quite don't understand what you are trying to tell me. Any other hint? Bare with me that I am not urging you to post a solution for me, I'd like to know what is needed to be done.
ok so I have set up a linked list: this is it:
in_p7.h
/* Structure definition */
struct Entry
{
char lastName[26], firstName[26], streetAddress[101];
Thanks guys, great suggestions all.
I'm interested in everything, really. It seems you've given me a broad enough list to cover it all.
Happy thanksgiving !
Hey, can anyone give me some good sites or links where i can look at source codes (open source...nothing illegal) just so i can learn, i seem to learn a lot more by example and following through...