Beginners - September 2010 (Page 10)

problems with math?
 
Im new to c++ and ive been working on this assignment but my math always comes out horribly wrong. Ive followed the instructions from the book step by step but ...
[6 replies] Last: 10000 for loan amount and 5 years values should start @ intere... (by bg102185)
i have a problem max_value
 
hi my problem is that it say that my max_value is undefined why? #include <iostream> #include <cmath> #include "graph1.h" using namespace std; int ma...
[1 reply] : Read this so that you can properly code the cin statement. http://www... (by kempofighter)
Problem using <iostream>
 
Hi all, I know basic C++ and am trying to relearn it. I have got Visual Studio 2008. I am trying to compile the following: #include <iostream> main ...
[6 replies] Last: Ahh got it. I haven't coded in over a year. Thanks. (by ChrisHowell)
it is true or false and why?
 
State whether each of the following is true or false. If false, tell why: a. !(p || q) is the same as (!p || !q) b. (!!!p) is the same as (!p) c. (p && q ...
[12 replies] Last: http://www.cplusplus.com/doc/tutorial/operators/ Question b is just... (by kempofighter)
by okason
Increment Array with For Loop
 
Hello all, I have been spending a lot of time on this site lately because I am taking a C++ class, I have found answers to many of my questions, now there are s...
[7 replies] Last: Albatross, Thanks for your feedback, actually I think that I am rea... (by okason)
by xyzt
an interesting function definition
 
Hello I've seen a function definition in a program. I've not seen something like that before.I tried it and it really compiles with no error. Here's the code: ...
[7 replies] Last: Alright. Making sure I'm not delusional. (by closed account Lv0f92yv)
by Kyon
cstdarg question
 
Hello there folks, 've got a question related to "variadic arguments" (defined in cstdarg or stdarg.h). Here's my code: #include <iostream> #include <stri...
[11 replies] Last: I'm willing to bet there's a more efficient algorithm for this that I ... (by PanGalactic)
cant find the problem with this function/loop
 
I have two functions here. One of them, get_spectro(), generates a random number between 12-37 to represent a fake number of elements. display_spectro() uses ...
[3 replies] Last: But the last element is what I am making sure isnt a copy. If the las... (by jopeters)
random int / setting Propabiliity
 
In my program (A simple based lemonade stand game) I want each "day" to have a non linear progression of temperatures. But I don't want to make it completl...
[2 replies] Last: rand() by itself is unbiased; it will generate every unsigned integer ... (by jsmith)
Formatting my output
 
Okay so I have this is the project that I have to write my code for: Make a table for the maxheatloss of a cylindricaltanks that has different H and R. W...
[4 replies] Last: in 184 line change = to == else if (qW==qR) (by Crafty)
Where am I going wrong converting minutes to "hours and minutes"?
 
I am trying to write this basic program to convert minutes to hours and minutes. I can get it to work but I need the singular minute and hour when the output i...
[1 reply] : const int hours=convert_to_hour(totalmin), mins=convert_to_min(totalm... (by Athar)
Creating array/vector array of duplicate instance types
 
Basically I want to create an instance of a class and make an array with duplicate entries of the previous instance created. I don't really think looping thr...
[9 replies] Last: Oh right, silly me. I put int instead of a constant number. Thanks. (by Krisando)
Speed of the CODE
 
I am in the process of doing some number crunching which involves multiplying several matrices (usually 12x12) frequently. However lot of the entries in these m...
[2 replies] Last: Problem solved. I just found ccode in Matlab. Its awesome ! (by kishor8dm)
how would I loop my program?
 
Hi everyone, my question is, how to I loop my program instead of having it terminated after one session? I want to terminate the program when the user states/ty...
[1 reply] : You can do that by using loops. See here for more information: http:... (by Athar)
by am0517
errors compile any programs including your tutorials
 
I am recieving this error message when trying to compile and run any programs. ">MSVCRTD.lib(crtexe.obj) : error LNK2019: unresolved external symbol _main ...
[16 replies] Last: For doing work, any *nix-like system is useful, from Ubuntu to OS X (F... (by kfmfe04)
undeclared identifier/uninitialized local variable
 
I have read and reread the chapter(s). I have used every thing I can think of (limited I admit) and all I seem do is change the error message from undeclared id...
[2 replies] Last: Thank You for your help. My instructor went over everything again this... (by alpha49er)
by Bri426
While loops
 
I'm new to C++ and am not doing so well in my class right now. I have an assignment due tomorrow that I'm really struggling on. I emailed my teacher and he help...
[4 replies] Last: Ask yourself what it is to land heads? In your code above, we see ... (by closed account Lv0f92yv)
by pooshi
rand() question in Maps
 
Hello. I have a question in regards to filling a map with a random number. What I am trying to do is fill my map with zero's then fill the map again with random...
[7 replies] Last: Time to change that. vectors are more basic and more important than m... (by sohguanh)
Function Argument's value doesn't change
 
When I pass a string by reference and modify it, why doesn't it change in the calling procedure? _declspec(dllexport) int ModStr(LPCTSTR str1, LPCTSTR str...
[2 replies] Last: Bah! I see. I fixed it and it works fine...thanks! (by RCM LittleC)
September 2010 Pages: 1... 89101112... 32
  Archived months: [aug2010] [oct2010]

This is an archived page. To post a new message, go to the current page.