Beginners - February 2015 (Page 15)

Loops and functions
 
Hi. I'm working on something that involves functions and loops. I'm having trouble understanding them and would prefer some one on one help as opposed to trying...
[3 replies] Last: Nothing gets more interactive than a compiler. (by LB)
Making pong clone in sfml as first project, ball not randomly moving
 
Ok, so I am a beginner in c++ and I am using sfml 2.2 to make a game using the IDE Code Blocks. I still have a lot to go, but here is the code I have (I am mak...
[1 reply] : You have to call srand(time(NULL)) once at the start of your program... (by LB)
by kiri
retune and refine this code, 4 erros as of now ...
 
Visual Studio has 4 errors 1 warning showing right now, but there is prob more due to my sloppy code. Can anyone point out some of the errors. #include <ios...
[6 replies] Last: Never mind I solved it and am deleting the code above because it is an... (by kiri)
im learnigand i would really apreciate some help
 
this is the error that is marking: Cpp\include\c++\mingw32" -I"C:\Dev-Cpp\include\c++\backward" -I"C:\Dev-Cpp\include" -L"C:\Dev-Cpp\lib" C:/Dev-Cpp/marco ...
[3 replies] Last: > indent the code as intuitively as possible. I think that you should ... (by ne555)
wage calculater need help!!!!
 
i dont know why when i run my code the output numbers come out incorrect example the gross pay comes out as $51562255152.00 can anybody tell me why this is happ...
[1 reply] : On the line regularPay= regularHours*payPerhour; what do you think t... (by kevinkjt2000)
appropriate way to write definitions
 
i was wondering which would be legal and illegal definitions. Im really not clear on how the members in public and private are assigned which is why im probabl...
[3 replies] Last: The class you showed in your original post only has two constructors: ... (by LB)
I need the solution
 
void InsertAttheend(int x) { struct Node* temp; struct Node* loc; temp=new Node(); temp->data=x; temp->next=head; loc=head; ...
[2 replies] Last: > the end of the circular linked list I wonder where that is. Your c... (by ne555)
wrong calculation outputting
 
The wrong calculation is being outputted in my program. It's giving me negative values subtracting from the initialBalance. #include <iostream> #include...
[3 replies] Last: @TheIdeasMan That was the problem, got the variables mixed up. Thank... (by closed account zT4NhbRD)
by Plearn
White Space and Input
 
Hello all. I'm working on a problem that takes a double as input and then a unit that comes after such as 12m for 12 meters and 12ft as 12 feet. The problem I'v...
[7 replies] Last: Okay. Thank you! That helped a lot! (by Plearn)
Oddcount Evencount and zero count problem. Program wont work?
 
Hey guys, I am trying to get the number to work and I can't make it seem to work any insight on how to do this? The program runs just fine, but when i enter 'b'...
[3 replies] Last: @tarikneaj A. is suppose to to find the largest number untill someone... (by Hidden Squid)
Question about a Program to print out prime numbers up to a given number
 
Hello, I am trying to write a program that will print out all prime numbers in a range of numbers (say from 0 to whatever). I am not sure why my code is p...
[1 reply] : This is my fastest solution: bool IsPrime(unsigned int n) { // 0 o... (by megatron 0)
Confused by File input/out statements
 
Input: The input file has the needed data on a single line. There is text as well as the numerical inputs. One sample input line is Pay rate: $15.50 per hour. ...
[2 replies] Last: THANKS! (by sfisher1987)
c++ calculator
 
I'm trying to make a simple calculator with trig functions. I need to add a bool loop to my program but I'm not sure how to. here's what I have so far... ...
[no replies]
Command line arguments
 
Alrighty, so my instructor doesn't seem to want to move on from this code. So I've had to modify it a few times since I last came on here for help and I'm stump...
[7 replies] Last: Your loop initializes i=0. argv is the name of the binary. argv is... (by keskiverto)
false position method
 
Write your question here. how can i write code in c++ using false position method plz give me some examples in c++
[1 reply] : Just Simply Google, "False position method c++". You'll get plenty of ... (by TarikNeaj)
Math problem
 
Here is my problem: "Write a grading program for a class with the following grading policies. a. There are two quizzes, each graded on the basis of 10 points....
[11 replies] Last: finalExam*0.5 + midTerm*0.25 + (quiz1+quiz2) * 0.125 I'm not really ... (by mighty asker)
Binding txt to exe?
 
Hello I found a solution for this problem: http://www.cplusplus.com/forum/beginner/157269/ A will just write variable values in a text-file, that text-file...
[no replies]
by gpoo
vector with 3 column matrix
 
Hi guys, I want to load the information from a file into a vector of a class type Voter. The file is basically a matrix though (ie. 3 columns) so not sure h...
[1 reply] : How is the Voter class defined? How is the Voter::operator>>( ... )... (by OxBADC0DE)
Writing from one file to another.
 
I'm trying to take data from one file ("predata"), add the data together, and write those sums into another file ("postdata"). I can't seem to figure out how to...
[1 reply] : You could simply open the same file for input and output, like this ... (by OxBADC0DE)
poly overloading plz help
 
The purpose of this Assignment is to be familiar with classes, Files and overloaded operators. The class you will be working on deļ¬nes one-variable polynomial...
[1 reply] : i write it #include<iostream> #include<conio.h> #include<fstream> usin... (by lolo966)
February 2015 Pages: 1... 1314151617... 52
  Archived months: [jan2015] [mar2015]

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