Beginners - June 2013 (Page 4)

Adding days to a date
 
We were given an assignment to add a number of days to a date. So I would add for example 10 days to...
[3 replies] Last: - first I will convert (day,month,year) (Gregorian) to Julian day numb... (by tntxtnt)
issue with looping a ifstream
 
Using any numbers found in a text file for example 3,5, and 8. It appears the the last number such ...
[2 replies] Last: ahhh that makes sense, Thank you. (by kingkong200)
Cin restriction and not rounding the results.
 
I have been trying to figure out how to limit the input up to two decimal points (e.g it would not a...
[no replies]
Find Lowest Score & Average
 
I'm close to successfully compiling a program for my Intro to Programming class. At this point I co...
[2 replies] Last: Thanks for the reply, I'll try that! (by stephen1101)
Why use contructor init lists?
 
What is the benefit of using constructor initialization lists as opposed to initializing variables i...
[5 replies] Last: Consider this: #include <iostream> int creation_index = 0; struct i... (by Lowest0ne)
program not returning proper values
 
Hello, I can't seem to figure out why my program isnt working. It keeps returning 0 kilograms and 0...
[8 replies] Last: Also, using doubles in a for loop is bad news, use ints and convert th... (by TheIdeasMan)
Making a poisoned code
 
Ok so my goal is to make a game. This code im wanting says if the player attacks, and the monster is...
[5 replies] Last: ok sorry guys I didn't know there was a difference between C++ and DML... (by hinotai)
Time Passed Between Dates
 
Does anyone have any feedback on how I could improve this program in making it faster or/and shorter...
[3 replies] Last: Anyone? (by GoranGaming)
method problem
 
Soo... the code in brackets working but other #include <iostream> using namespace std; ...
[3 replies] Last: ^^ really thank you :) this->x_=p1.x_+p2.x_; this->y_=p1.y_+p2.y_; ... (by purpleNoise)
Issue with ofstream
 
I'm having some difficulty getting my program to write into a file using ofstream. I checked my cod...
[9 replies] Last: Thank you everyone for all your help! It turns out that the issue wa... (by aguycalledjoe)
Problem
 
Whenever I don't understand how to solve a C++-assignment from a book or from somewhere else, I just...
[6 replies] Last: In that case, you need to try and break down your task into smaller, s... (by MikeyBoy)
if statement always evaluated to true
 
Hi, I was doing some work on my game, and rewriting it to avoid repetition of code, and have come ac...
[10 replies] Last: After about 4 hours of searching, I finally found what the problem was... (by manudude03)
Remainder Command
 
Is there a command to completely remove the remainder of a double variable type? I want as an exam...
[3 replies] Last: Don't worry, I found something that worked, the floor function :) (by GoranGaming)
vector multiplication
 
Hello, I have a vector that is filled with N values, now I need to multiply this vector with it...
[1 reply] : This would do... for(std::size_t i=0;i<myvector.size();i++) { ... (by a k n)
Operator conversion
 
Hi :) If I have class String and I use operator conversion to 'print' an object with cout,why do ...
[5 replies] Last: operator<< for char* is a nonmember operator: http://en.cppreference.c... (by Cubbi)
How do i do this?
 
Ok so sorry but im a COMPLETE beginner and the most experience have in coding is from a tutorial th...
[1 reply] : Well, in order to get the change part right you would need to look int... (by Script Coder)
by Pojky
Looking for some help opening the door
 
I am looking to learn c++ for the purpose of video game development. I have a entry level understand...
[2 replies] Last: http://www.cprogramming.com/c++book/ ive been going through this e-bo... (by Paoletti301)
printing numbers from an array
 
Im a bit confussed on how to print the numbers from inside my array. I know i have to use a for loop...
[3 replies] Last: Thanks guys made it clear what i was doing wrong! T (by mauri11)
by Nyxe
Base10 to Base2 String conversion.
 
Greetings. This is my first official post on the C++ Forums. I have very little experience with the ...
[10 replies] Last: Would it be possible for you to comment and explain each part so I ca... (by Catfish4)
Please tell me of these are nested loops??????
 
Is this a nested loop??? The code does what I want it to do. //#include <stdafx.h> #include ...
[1 reply] : Yes it is, but might i make a suggestion? for ( C blah blah blah ) {... (by Paoletti301)
June 2013 Pages: 123456... 49
  Archived months: [may2013] [jul2013]

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