Beginners - June 2013 (Page 48)

Merge sort
Hello, I have always asked myself what is merge sort and how to I use it in a code. I will be glad if someone can tell me how.
Jun 1, 2013 at 7:50pm
[1 reply] : http://www.cprogramming.com/tutorial/computersciencetheory/mergesort.h... (by Fransje)
Errors Using Random Numbers in a Class
Hi, I've been working on a simple version of Mastermind using Microsoft Visual C++ 2010 Express. I use a random number generator to create the codemaker's code....
Jun 1, 2013 at 7:17pm
[2 replies] Last: Thanks, it worked! I also think I understand why I was getting C2059 -... (by closed account Nw0DjE8b)
How to read file in class?
I'm trying to read a file in a class, I do not know what I am missing. How do I call the void readfile that is in my class? Would really appreciate some help! ...
Jun 1, 2013 at 6:59pm
[2 replies] Last: Sry i forgot to specify what I was doing. Im trying to open up the fil... (by Gluttons)
How do I check one variable before inputting the others on the same line?
cout << "Enter a phone number(Enter Q to quit): "; cin >> a >> b >> c >> d >> e >> f >> g >> h; In this program I'm trying to get a phone number. I...
Jun 1, 2013 at 6:59pm
[6 replies] Last: He won't be able to use 'q' to quit. Because there is a chance the num... (by gobiking)
I'm so confused!!! Help
Basically, for the pass 5 months I have been learning c++ out of a book called beginning c++ through game programming by Michael Dawson. It's great but all it ...
Jun 1, 2013 at 6:07pm
[1 reply] : And I fail to see how learning texted based games will help me learn ... (by MiiNiPaa)
if statement didnt work correctly
Hello, i have a program where inputed numbers must be in interval from 2.0 to 5.0. if it's true, second if block must run forward, if not true, further blocks m...
Jun 1, 2013 at 5:31pm
[9 replies] Last: Thank you alot, problem solved :) (by sermanas)
Output Data from Input.txt to Output.txt
Say I have input.txt, which looks like this: 8 7 6 5 4 and output.txt, which looks like this: 6 5 4 3 2 1 I want to get it looking like thi...
Jun 1, 2013 at 5:13pm
[3 replies] Last: Does set work with strings? Yes, but you should change every int to... (by MiiNiPaa)
get weird result
this from documentation i changed the int data type to char to save 3 bytes but when i try to run this program i get strange charcter instead of value ...
Jun 1, 2013 at 5:09pm
[7 replies] Last: It have internal representation as integer. It stores numerical repres... (by MiiNiPaa)
Deque Help!
Good day guys! can someone explain to me the exact use of deq.assign(n,elem);? ,how can i display the value of it in the prompt and how this code(below) obtain...
Jun 1, 2013 at 5:08pm
[2 replies] Last: my problem is that how this program list the output 7,5,3 and well, yo... (by Cinematic)
Program in C++
How to solve it? A trader wants to survey the profits of goods he sells. For this he had to enter each commodity, the commodity code (an integer between 100 ...
Jun 1, 2013 at 3:14pm
[3 replies] Last: Hmm I can give you a tiny skeleton to start with to nudge you in the r... (by gobiking)
meaning of the statment
const char * GetName() const; this is a member function of a class ..what is the exact meaning of this statment ? what does the const in start represent ?
Jun 1, 2013 at 1:48pm
[1 reply] : first const represent that it returns pointer you cannot change values... (by MiiNiPaa)
Dynamic array
Write a program that reads an unspecified number of scores and determine how many scores are above or equal to the average and how many scores are below the ave...
Jun 1, 2013 at 1:36pm
[7 replies] Last: hey, you could use malloc() function >malloc() >C++ Just... Don't An... (by MiiNiPaa)
compiles fine, but crashes after printing first value
The program crashes on execution after printing the first value, meant to be printing position of all occurences of an option(struct.option) in string and also ...
Jun 1, 2013 at 12:50pm
[3 replies] Last: The problem is that after exiting the internal while loop string becam... (by vlad from moscow)
by Bevan
Where to from here?
Im not sure how to phrase this question, which is possibly why im not getting anywhere in the search results,however here goes - About 7months ago I started ...
Jun 1, 2013 at 11:39am
[2 replies] Last: let me advice you something from the real world: go out there, learn, ... (by Rechard3)
by Andym
read from file
So part of my school assignment is to read from a file. In my file, I have "0 50 100". Why is it that when I cout the contents of Line1, Line2 & Line3, I get ...
Jun 1, 2013 at 11:39am
[2 replies] Last: Thanks. Maybe this is one of the quirks of Xcode. (by Andym)
by Vetal
Console output of unsigned chars (initialized by hex) gives cyrillic output
Hi, please, help to understand. PROBLEM:I make the output with cout of unsigned chars, that are initialized as hex and receive ciryllic symbols on output ...
Jun 1, 2013 at 10:05am
[8 replies] Last: Thank You, Guys, I thought, that hex will be outputted as chars lat... (by Vetal)
I'm Confused and it's only my second program :/
When i run my program, it's suppose to say Good if you write your name correctly and meant to repeat itself if you didn't, for some reason it always say Good ev...
Jun 1, 2013 at 8:58am
[4 replies] Last: A const variable eg. a const std::string can't be modified after it ... (by JLBorges)
by Gain
Can't find Exe?
Ok, so I have this simple code, but when I try to build/run it's telling me it can't find the .exe file in my debug folder for my program. I checked the file an...
Jun 1, 2013 at 8:57am
[2 replies] Last: you forgot semicolon after the return 0 im newbie my self and like twi... (by Rakanoth)
fatal error: iostream: No such file or directory
My first program won't run. it says" fatal error: iostream: No such file or directory". Can someone help? Thanks in advance. Rayson #include <iostrea...
Jun 1, 2013 at 8:48am
[12 replies] Last: > a beginner wouldn't need to worry about malicious software in their ... (by JLBorges)
warning:assignment makes integer from pointer without a cast.
I'm trying to make the function *searchterm_generator return an array of pointers to strings but I get the warning at store = query_term (where i try to make ...
Jun 1, 2013 at 8:48am
[12 replies] Last: what i ended up doing was add all the strings to char arrays in a stru... (by sanzou321)
June 2013 Pages: 1... 46474849
  Archived months: [may2013] [jul2013]

This is an archived page. To post a new message, go to the current page.
Registered users can post in this forum.