2,827 Posted Topics

Member Avatar for espm1000

[QUOTE=espm1000;732849]Hello everyone, I am new to computer science, and thus far this semester I have not needed any help in writing a program even though I am stuck with a professor who struggles to get a clear point across. He is a great guy and tries to make sure we …

Member Avatar for VernonDozier
0
329
Member Avatar for mrboolf

These links might be helpful. [url]http://www.deitel.com/articles/cplusplus_tutorials/20060325/index.html[/url] [url]www.cis.gsu.edu/~mmoore/CIS3280/lectures/exceptions.ppt[/url] You need PowerPoint for the second one.

Member Avatar for mrboolf
0
121
Member Avatar for Fiery Demon

[QUOTE=Fiery Demon;732078]Thanks :):) However, I can't get the oval, oval2, neck, eye, eyes to move up and down. I'm using the code my instructor gave me and it isn't that helpufl :S[/QUOTE] It's considered bad form to post verbatim threads on two separate forums at the same time. Read post …

Member Avatar for VernonDozier
0
123
Member Avatar for Ancient Dragon

[QUOTE=GrimJack;728684]Yes, it is why I won't feel very good about the election until inauguration day. Speaking of which, I have heard that there might be a movement to make inauguration day January 1st - why let 2 weeks go by with no president (so to speak). What do you think?[/QUOTE] …

Member Avatar for itdupuis
0
357
Member Avatar for Alex Edwards

When in doubt, write a program! It's faster and more accurate than research. I did this on Dev C++, but is it a reasonable assumption that it's the same everywhere? [code] #include <iostream> using namespace std; int main () { int a = 8 * 9 % 5; cout << …

Member Avatar for Alex Edwards
0
7K
Member Avatar for amerninja2

I don't have that much experience with making C++ GUIs. You may want to try Microsoft Visual C++ and their Forms feature. The Express version is free, but I don't know if it includes the Forms options, which is mostly drag and drop and easy to use. You may need …

Member Avatar for amerninja2
0
179
Member Avatar for c++ prog

[QUOTE=c++ prog;731651]hi we have a programming assignment which computes the volume of a barrel. I don't have a compiler yet and java is not yet recognized by my computer yet because I haven't downloaded any JDK yet because I don't know which one to download...Here's my code so far...Please just …

Member Avatar for VernonDozier
0
146
Member Avatar for lilnedy

[QUOTE=lilnedy;731470]I attached a picture of what it should look like but just dont know how to start the thing. Back to reading more. Thanks for the advice.[/QUOTE] By "what it should look like", does this mean this is what it is REQUIRED to look like or is this somebody's advice …

Member Avatar for VernonDozier
0
109
Member Avatar for king_blat

Use code tags: [noparse] [code] // paste code here [/code] [/noparse] The compiler will tell you exactly what the error is and where. Read the compiler messages closely. You'll get some warnings and an error. Read them carefully. Look at this line and see if you can find it: cin …

Member Avatar for mrboolf
0
121
Member Avatar for piznut25

Best way to handle the problem is to start commenting parts out until it compiles. Start by commenting out all the function declarations and the functions and everything but this: [code] int main () { return 0; } [/code] When that compiles, uncomment the #include statements and const declarations: [code] …

Member Avatar for VernonDozier
0
135
Member Avatar for Nick6425fl

[code] void Output(double total, int sqft, double paint, double labor) { cout << "The number of gallons of paint required is ___\n"; cout << "The hours of labor required is ___\n"; cout << "The cost of the paint is $" << paint << endl; cout << "The labor charges are …

Member Avatar for Nick6425fl
0
1K
Member Avatar for Nick6425fl

Which line? You can either use C++ code tags: [noparse] [cose=cplusplus] // paste code here [/code] [/noparse] which add line numbers, and you can reference the line number, or you can highlight the relevant line in red. Give the compiler error too please.

Member Avatar for Nick6425fl
0
148
Member Avatar for Nick6425fl

[QUOTE=Nick6425fl;730341]I'm still learning about all of this...I'm sure when I look back at this post in a couple of months I'll laugh. Thanks for the reply, but what do you think that line should exactly be to make that code work?[/QUOTE] If you format/indent your code, it'll be much easier …

Member Avatar for Nick6425fl
0
120
Member Avatar for piznut25

[QUOTE=piznut25;730248]I am a beginner and our teacher gave me this assignment. I am going to be writing some code tonight but I am having a tough time starting. should I have a seperate function to handle both manual and file input parts?[/QUOTE] [quote] At a minimum, you should include separate …

Member Avatar for VernonDozier
0
97
Member Avatar for Nick6425fl

As to the error, lines like this are illegal, where highest is defined as a string and salesSE is a double: [code] if(salesSE > highest) [/code] You can compare two strings and you can compare two integers, but you can't compare an integer and a string like that. You should …

Member Avatar for VernonDozier
0
288
Member Avatar for gangsta gama

[QUOTE=gangsta gama;729489]Thank you, ArkM. I will try what you did. The compiler I am using is Dev c++ and it is not working right now, so that is why I am writing back. I have one question though... what does setprecision do? Thank you, Gangsta Gama[/QUOTE] Best way to learn …

Member Avatar for ArkM
0
170
Member Avatar for swbuko

[QUOTE=swbuko;729210]yea, I need to exchange x for the the number. such as 3, 4, 5 etc. Ill run a while loop to get my x,y coord.[/QUOTE] You probably need to post some code and provide an example of a run of the program, even though you haven't written the program …

Member Avatar for skatamatic
0
239
Member Avatar for WesFox13

[code] getline(istream& fin, string& num_of_isbn, char '\n'); [/code] This isn't a function call. It's a function prototype already defined in C++, so you don't need to define it. Leave the variable types out. The compiler will figure out what the types are and what function to call: [code] getline (fin, …

Member Avatar for VernonDozier
0
97
Member Avatar for localp

[QUOTE=localp;728316]i need to write a c++ function that could read in the values of a text file, but in the text file we need to eliminate duplicate values; for example we may have values like ;;;; this is a text file, and it contains the above students, there first name …

Member Avatar for iamthwee
0
145
Member Avatar for cajuninms

[QUOTE=cajuninms;727983]I am now getting this error after adding "using namespace std;" to both the header and implementation: Undefined first referenced symbol in file main 3/crt1.o 1d: fatal: Symbol referencing errors. No output written to a.out collect2: 1d returned 1 exit status[/QUOTE] Post the updated code please. Last time you made …

Member Avatar for VernonDozier
0
108
Member Avatar for sAeNxNyA

[QUOTE=sAeNxNyA;728304]its not a binary search tree.....just a simple binary search plz help :([/QUOTE] You still need to repost using code tags so it's readable please. Either: [noparse] [code] // paste code [/code] or below (which adds line numbers and syntax highlighting) [code=JAVA] // paste code [/code] [/noparse]

Member Avatar for BestJewSinceJC
0
93
Member Avatar for lllllIllIlllI

Something times something else mathematically always depends on what the word "times" means and the units involved. Multiplying money is problematic because: $1 = 100 cents $2 = 200 cents So if $1 x $2 = $2 and 100 cents x 200 cents = 20,000 cents = $200, we have …

Member Avatar for lllllIllIlllI
0
158
Member Avatar for The Dude

What about Zane Starkewolf's robo-calls? Those deserve at least an honorable mention. [url]http://www.youtube.com/watch?v=c9_BAxI3Mik[/url]

Member Avatar for sneekula
0
45
Member Avatar for andrewama

You have two threads on the same topic. [url]http://www.daniweb.com/forums/thread154728.html[/url]

Member Avatar for grumpier
0
169
Member Avatar for NinjaLink

[QUOTE=NinjaLink;724248]Here is soe things that my compiler says. I don't know how to copy and paste, so i will type some of it manually: In function int main() 10 - no match functoin for call to 'personType::personType(const char(8))' candidates are: personType::personType(const personType&) 16 - 'firstperson' undeclared 17 - 'lastperson' is …

Member Avatar for NinjaLink
0
1K
Member Avatar for Aia

The video you link is from 2000 and has this title: [B]Obama's Crime Against Humanity—Infanticide[/B] Hardly anyone had even heard of Obama in 2000. I certainly didn't watch the whole video, but what does Obama have to do with an abortion video from 2000?

Member Avatar for Lardmeister
0
368
Member Avatar for kotkata

[QUOTE=kotkata;722930]Thanks for helping me. I really appreciate it. In fact, you helped me more in this than did the TAs in one hour. (She kept suggesting that I use another loop to break me out of the eighty "15"s which did not work at all) As for counting the numbers, …

Member Avatar for skatamatic
0
144
Member Avatar for bahr_alhalak

[QUOTE=bahr_alhalak;719111]i'm sorry my frind , but 'm not a student . i'm only learner . i need to know more ,about programing . i am so sorry[/QUOTE] You're not a student? [quote] SFDV3001 (Algorithms and Data Structures) Semester 1, 2008 Due date: October 25, 2008 (10 %) [/quote] Post the …

Member Avatar for dickersonka
0
268
Member Avatar for Se7Olutionyg

[QUOTE=Se7Olutionyg;722082]how about the second term[/QUOTE] I've never heard of the word "Procuste". Are you sure it's spelled correctly?

Member Avatar for ddanbe
0
168
Member Avatar for clutchkiller

[QUOTE=clutchkiller;722922]How would you put a counter into an If statement to check if there is a specific amount of chars, Say 'x' or 'y'? Thanks[/QUOTE] Too vague. Specific number of chars in what? Some string? What are x and y?

Member Avatar for DemonGal711
0
97
Member Avatar for cam875

I get warnings, not errors on lines like this: [code] if (val1 > 16777215 && val1 <= 4294967295) [/code] [quote] [Warning] this decimal constant is unsigned only in ISO C90 [/quote] You are using && correctly. You've declared val1 as a signed integer and 4294967295 is out of the bounds …

Member Avatar for cam875
0
110
Member Avatar for msashley09

[QUOTE=msashley09;722099]ok another thing is...i need someone to run it if they can because it also wont display correct roman numerals/decimals...... i messed something up.[/QUOTE] Run what? I don't see any code.

Member Avatar for Salem
0
127
Member Avatar for Boudou

[QUOTE=Boudou;722034]#include <stdio.h> #define SIZE 16 int* biggest(int *a, int count); int main(void) { int values[16] = { 47, 17, 38, 91, 33, 24, 99, 35, 42, 10, 11, 43, 32, 97, 108, -8 }; int *p; p = biggest(values, SIZE); printf("the biggest element in the array is %i\n", *p); return …

Member Avatar for skatamatic
-1
108
Member Avatar for JackDurden

[QUOTE=JackDurden;722011]Im having trouble seeing this recursion function through. Say I have an 8 by 8 array how would I get the search function to "see" into the middle of the 8 by 8 array. Positions (4,4), (4,5),(5,4),(5,5). [/QUOTE] Don't know what you mean by "see into the middle of the …

Member Avatar for skatamatic
0
68
Member Avatar for NinjaLink

My guess is that you are supposed to have two functions, not one here: [code] int toyType::getStock(int st) { stockcount = st; return st; } [/code] You are simply returning the value you passed to the function here. Thus you really aren't "getting" anything. There's no new information. You are …

Member Avatar for NinjaLink
0
135
Member Avatar for uim_1977

[QUOTE=uim_1977;722051]People what do i do wrong, i'm new to the forum, but for some reason i'm not gettig any ansfers to my questions, please tell me what do i do wrong???? Thank you.[/QUOTE] You're either dumping too much code without being specific about exactly where to look: [url]http://www.daniweb.com/forums/thread153541.html[/url] or you're …

Member Avatar for VernonDozier
0
92
Member Avatar for robgeek

[QUOTE=robgeek;721046] [code] double Mean(const int Data[][4], int r[][4], int c[][4]) { int Avg[5][4]; int sum=0, i; for(int r=0; r<5; r++) for(int c=0; c<4;c++) Avg[r][c]= r[r][c]+c[r][c]; return sum; } [/code] Any help is appreciated. Thanks.[/QUOTE] Here is your code simplified: [code] double Mean(const int Data[][4], int r[][4], int c[][4]) { return …

Member Avatar for robgeek
0
5K
Member Avatar for dbwalters

[QUOTE=dbwalters;713225]One thing I should add is that when I try to plug in a number less than 0, I get an error. When I try a number between 0 and 1 I get this: 10(0.1) (lg 0.1) > 2(0.1)^2 -1 > 0.02 Thus this is why I pick B as …

Member Avatar for aashish.raina
0
112
Member Avatar for dmanw100

[QUOTE=dmanw100;720132]Is there an easy way to open an fstream using a string? My code is as follows: [CODE]bool openArray(std::string *arrayFileName, int *width, int *height,int *myArray) { std::fstream BoardFile; BoardFile.open(*arrayFileName);[/CODE] I obviously cannot use this method since *arrayFileName is not char* but is there another way to do it?[/QUOTE] Well you …

Member Avatar for kux
0
147
Member Avatar for Newguy89

Code tags: [noparse] [code=cplusplus] // paste code here [/code] [/noparse] You have this call: [code] guess_game(); [/code] and this prototype: [code] void guess_game(); [/code] but the function itself is this: [code] void guess_game(int N) [/code] The prototype needs to match the implementation and the function call. The function call should …

Member Avatar for chococrack
0
86
Member Avatar for VernonDozier

I have a program for which I am designing a help menu. The program allows you to add squares, ovals, and other shapes, and move them, rotate them, etc. I'm setting up some HTML pages that explain how to do different tasks. So when the user pulls down the help …

Member Avatar for VernonDozier
0
122
Member Avatar for Se7Olutionyg

WHICH { ? You have a bunch of them. In addition to what Sci@phy mentioned, you have a bracket problem here too: [code] void processChoice (int userChoice) { if (option == 1.0) { cout<< "How many Coca-cola would you like: " << endl; cin>> cocaout; } else if (option == …

Member Avatar for VernonDozier
0
136
Member Avatar for VernonDozier

OK, this is a follow-up to this thread, which I have marked solved. [url]http://www.daniweb.com/forums/thread152797.html[/url] I changed things from GIF to PNG and that seems to solve the saving issue, but there is a new issue. I'm trying to create a semi-transparent circle as an image, which can be saved. The …

Member Avatar for VernonDozier
0
175
Member Avatar for ShadowOfBlood

[code=cplusplus] #include <iostream> #include <cmath> using namespace std; double pif(double); //Fucntion to determine value of pi int term; //Variable to count terms int main() { cout << "Value of Pi" << " " << "Number of terms" << endl; cout << pif(3.0) << " " << term << endl; cout …

Member Avatar for VernonDozier
0
593
Member Avatar for Jason123

{ private: static int id; char name[20]; char age[20]; double salary; public: Employee(); char *getDepartment(); double getSalary(); void print(); }; int Employee::id = 0; int Employee::getID() { return id; } void Employee::Add(char n[], char a[], int size) { name = n; age = a; } int main() { char name[20]; …

Member Avatar for Jason123
0
188
Member Avatar for koman

The spacing in your code makes it very hard to read: [code=cplusplus] #include <iostream> using namespace std; int main () { int j; int t; int p; int num; cout << " Please enter an even integer greater than 2: "; cin >> num; for ( int i = 2 …

Member Avatar for stilllearning
0
165
Member Avatar for sistasweetpea

Define "not working". Is this a verbatim copy and paste of what the instructor wrote? What's the question? if "not working" means that it doesn't read from a file, you're right. It doesn't do that. I imagine your job is to change it so it does read from a file.

Member Avatar for sistasweetpea
0
116
Member Avatar for akira_shinizaki

[QUOTE=akira_shinizaki;717957]hmm an attempt....honestly, i really don't know how to write the code because functions that I know only conditional IF and increment and decrement for now. It really help me if you can show me some example of it.[/QUOTE] Focus on the easier part first, the summing of the numbers. …

Member Avatar for VernonDozier
0
94
Member Avatar for ruby T.

No one is going to do this whole assignment for you. Post what you have done and what you need help with.

Member Avatar for peter_budo
0
179
Member Avatar for Se7Olutionyg

A 32-bit system can store from about -2 billion to 2 billion in an integer. Something like that, so 10,000,000 is within that range. A 16 -bit system can store some thing like -32,000 to 32,000 in an integer, so 10,000,000 is outside of that range. This line is incorrect …

Member Avatar for VernonDozier
0
215

The End.