Beginners - June 2015 (Page 9)

How to decrement a value within a loop?
 
Hello, I'm having quite a bit of trouble with this question. I'm following along with a book and hav...
[2 replies] Last: Feel incredibly stupid now. 'i' didn't even need to be present. Markin... (by Hcode91)
by rex21
First output is always wrong in do-while loop?
 
Hello. I'm new to C++. I was just practicing this code and I noticed that even if I input 5 or 1 or ...
[3 replies] Last: Thank you, MiiNiPaa. Actually I initially wrote the code with While lo... (by rex21)
by Xentro
Map/Set iterators not incrementable.
 
So I have the following piece of code: std::vector<std::string> Monsters; for (auto & e : Game::...
[10 replies] Last: Ok you fixed it, it was indeed the call of my CheckMonsters function w... (by Xentro)
by calz
Change every four letter word to 'love"
 
Write your question here. #include <iostream> #include <string> #include <cctype> int m...
[15 replies] Last: Thank you very much guyz. (by calz)
by Dmytro
As in the method of the class to create a dynamic array of objects and initialize values each of these??
 
As in the method of the class to create a dynamic array of objects and initialize values each of the...
[16 replies] Last: You can show the code how that would be an object of class dysk it can... (by Dmytro)
object variable does not stay the same, why?
 
Write your question here. below you can see that my constractor is giving my object a random numb...
[4 replies] Last: Overall, the rabbit::rabbit( int r ) { int b = r%10; int rabbitAg... (by keskiverto)
by Ch1156
Why doesnt this work?
 
I am trying to get the entire contents of a text file, and i am looking at this push back reference ...
[2 replies] Last: ah ok thank you. (by Ch1156)
Trying to understand this program?
 
I'm trying to understand the following program which is given in the tutorials section of this websi...
[3 replies] Last: A function can be implicitely converted to pointer to it. So an addres... (by MiiNiPaa)
Unique Pointers
 
Hi, I'm trying to get some practice with smart pointers (specifically unique_ptr), but my compiler d...
[2 replies] Last: Use the reset(...) member of unique_ptr: unqSaPtr .reset (new Savings... (by coder777)
clearing c buffer
 
when using scanf, how do i clear the input buffer without using fflush?? im using it in linux and so...
[1 reply] : http://c-faq.com/stdio/stdinflush.html http://c-faq.com/stdio/stdinflu... (by MiiNiPaa)
How to continue getline, find keywords.
 
I'm trying to read a set of numbers from a large text file, and write them into a second text file. ...
[9 replies] Last: never mind, I see you changing the value of a1out and then resetting i... (by SamuelAdams)
Summary of number of times program runs
 
So, I got my program to work, finally. But I just noticed I did it wrong (kind of). Every time the...
[6 replies] Last: @Elzcode, Here I have used the while loop and only implemented plus ... (by CodeWriter)
array bounds checking while reading data
 
Hello everyone, I have a program I am trying to tackle by breaking it down into workable parts, th...
[2 replies] Last: Thank you so much!! By adding that other flag, solved everything. Than... (by jpanther)
by nofish
const char*
 
Hello, new member here currently learning C++ in self study. I have the following code: con...
[9 replies] Last: - pchar 0x00417838 "123456789" const char * 49 '1' const char (by Dmytro)
Member initialization lists in composition?
 
Why is it necessary to use member initialization lists when doing class composition? Is that just wh...
[7 replies] Last: Actual or admitted date of birth? Andy (by andywestken)
C scanf error
 
Write your question here. In my code, scanf is keep passing leftover values to next scanf. I alread...
[no replies]
Program crashes for generated string
 
Here I am trying to implement longest common sub-sequence algorithm for two randomly generated strin...
[4 replies] Last: okay :) (by spsrijan)
by madara
string pallindrome
 
i am writing a program of string pallindrome, code is compiling successfully but on running it accep...
[5 replies] Last: And remember, variables are not automatically inititlized in C++ so if... (by andywestken)
Printing a string of Characters and integers
 
Hello, I was wondering if there is a way to have a program output a string with both characters a...
[3 replies] Last: Why can't you just get the Powershell script to read the file? Or wil... (by andywestken)
June 2015 Pages: 1... 7891011... 32
  Archived months: [may2015] [jul2015]

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