sweet that last one worked...thanks alot for the help people really appreciate it ! :)
Type: Posts; User: devilsknight
sweet that last one worked...thanks alot for the help people really appreciate it ! :)
Say if i had a user enter a character
printf("Enter operation code: ");
scanf("%s", operCode);
if(operCode == 's')
{
some code to run
}
Alrighty...here's my problem...i have to get data entered from a user and insert it into a structure...i ask the user to give me a operation code (i = insert), i go to the insert function create my...
it is homework...but i wasnt asking for someone to code it for me
i was asking for help on which function i should use...i'll be doing the rest of the program...is there a problem with that ?
...
Would there be a string function for the following ?!
Compares two strings for equality. If they are equal, zero is returned,
otherwise the difference in value between the first two non-matching...
well thanks to everyone for their suggestions except the last poster...i will try to look up what i can do
thanks again
b
yah the project states that i must let the user input what size then pass it along...
so how do i fix that error ???
i'm been workin away on it and have no clue how to work it
ok i think i figured out a way around it...i ask the user for how many numbers it wants to enter...then pass that number to a function and create an array
however i get this error:
constant...
That stuff sounds kind of hard and probably way ahead of what i'll learn in this class
here's the teachers question...the rest of the question i left out cause i pretty much know how to program...
what i meant was if i didn't know what the user was to enter, for example if i asked for integer numbers...and he entered 20 how would i tell the array to be that big ?
thanks
How would someone go about creating an empty array that would be filled from user input ???
Thanks...i have no code for this yet cause i have no clue how to start an empty array
thanks
...
sweet ok fixed that problem
now one last problem
if i compare 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
to 2 4 6 8 10 12 14 16 18 20 22 24 26 28 30
i get no matches
but if i...
How about if i do something like this
int findIntersection(int set1[SIZE], int set2[SIZE], int intersection[SIZE], int numIntValue)
{
int x = 0;
int i = 0;
int y = 0;
int a = 0;
int b;
Not quite understanding how that works...could someone explain more ?
Any other suggestions ?
And does my code look alright ?
thanks for your time
b
I need help passing values, i'm still unclear how to pass these and
also if i want to search two (sorted) arrays for same values how would i do that and how would i then take that value and store it...
Ok i changed the code at the top. How does that look, i don't have a compiler here at work.
Thanks for everything guys...appreciate it.
devilsknight
and where would i place the output ex: "The number was found" ?
ok i changed the code around, but what would i use now inside of the function isMemeber to return true or false ? sorry i'm still very new at this.
and what does std::... do exactly ?
if you...
i changed over the array from float to int...what do you mean by boolean ? how would i return a boolean ?
thank you for your help
lol yah...k just for the record then, where am i using C and where am i using C++ ? Our prof never quite told us when we swtiched over to C++ ?
Thanks for your help.
The program works...however for the question it states
"The function should print true if the value is found in the array or false if the value is not found in the array."
Would this be the way...
Wicked thanks alot for the help guys...it's always the small stuff that i miss
Appreciate it
I'm trying to pass an array...and add up it's total, however i'm always getting 0 as my answer. Someone tell me what i'm doing wrong...thanks...eventually it's going to calculate standard...
How would i go about writing a simple program that would display the range of values for say
integers
long
shorts
thanks for your help