Beginners - February 2012 (Page 26)

Best Alternative to system() with example?
 
I was wondering what the BEST alternative is to start an application. I'm using system() for the moment but I've read all over that system functions are ill-ad...
[9 replies] Last: @ Null, The top Windows 7 worked. (by TruYadoo)
Initialising unique variables in a while loop?
 
Hi, I have an if statement nested in a while loop. Everytime the if statement is true I need to store a variable which can be used after the while loop is fi...
[1 reply] : vector<int> variableStore; while (somecondition) { // generate som... (by Moschops)
str.replace()
 
I'm trying to make code that writes code based on a two text files and user input, but I'm having issues with one line of it. I'm trying to replace a certain s...
[7 replies] Last: These are not the droids you are searching for. (by cire)
Basic Loop Help
 
Hi, I need help with the programming of a basic loop while loop that keeps repeating until the user has entered either "N" or "Y". This is what I have go...
[4 replies] Last: You could just invert the logic. do{ // Stuff while ( chr != 'y' ... (by ciphermagi)
Question about Tutorial
 
I have a question about some code from the "Exceptions" tutorial on this site under the "standard exceptions" section. Here's a link: http://cplusplus.com/do...
[2 replies] Last: Okay, thanks. Makes sense now. (by CJC0117)
why the result of the follow code is zero?
 
Shouldn't it be 23? Thanks! // trying to compute the division of two integers in c++ #include<iostream> using namespace std; int main(){ int i =...
[4 replies] Last: LOL. Sorry, I am just a daft prick. (by subjugater)
by pepper
using structures and unions
 
how should a structure be used in other functions? how should a prolem like this be solved? Consider the abstract data type, aStudent, described as: struct a...
[1 reply] : The same way as classes... Class == Struct == Union, except: Classes ... (by LB)
problem using cin inside DWORD Thread
 
hello guys this is my first post am trying to take input from console using cin from a thread when i enter the characters and press enter the program crash...
[1 reply] : Maybe you forgot to allocate statename ? Also, I don't think it's a g... (by Null)
Sieve of Eratosthenes
 
Hello there. I have this in General C++, but I feel like this section gets more attention. So please pardon my repost. Im working on a euler project problem. I'...
[3 replies] Last: Thanks much. I have investigated the unsigned long long, but its seems... (by jwroblewski)
conversion from ' ' to non-scalar type ' ' request
 
I'm currently getting 21 C:\Users\Endre\Documents\CISC 3110\Chapter 7\hw#3\Bank.cpp conversion from `const Account*' to non-scalar type `Account' requested as...
[2 replies] Last: I managed to solve the issue by myself but just to answer your questio... (by s0u1k33p3r)
Understanding Pointer sizes
 
http://pw1.netcom.com/~tjensen/ptr/ch2x.htm "Also we have learned that on different systems the size of a pointer can vary. As it turns out it is also possible ...
[6 replies] Last: There are four categories of pointers; each may have a different size.... (by JLBorges)
Bubble Sorting program not working properly
 
I created a program that performs a bubble sort in ascending order to 10 integers. It prints what happens after each pass and shows which values at the end of ...
[1 reply] : How interesting, I just tried your problem and got this output: Ente... (by Stewbond)
a C++ program with a function named FindMax that has two parameters
 
Task: Write a C++ program with a function named FindMax that has two parameters, one in type constant pointer to constant double array (i.e. const double* con...
[5 replies] Last: thanks Pravesh Koirala & therockon7throw!!!! these are new code but I... (by kyky365)
by lare26
SFML Shape::Line Problem
 
I am trying to draw a line from Sprite to Sprite2. The program seems to draw from only the starting position of Sprite. When I move Sprite the line still comes ...
[1 reply] : Oops. I guess I should have used GetPosition() rather than GetCenter()... (by lare26)
function return
 
When calling a function that has a return type, is it necessary to use the return type? Suppose the function modifies certain values and the return may or may n...
[no replies]
What is wrong with this program
 
#include <cstdlib> #include <iostream> #include <string> using namespace std; int main() { string x; cout << "What's your husbands name? "; ...
[3 replies] Last: where did you learned from? this page is a good reading for you... ht... (by chipp)
Input causing infinite loop..
 
Program asks for a 1 - 3 input. And it supposed to display an error for anything else including letters etc. do { cout << "Option: "<< endl; cin >> option; ...
[5 replies] Last: Try using if-else. do { cout cin >> option; if (1) do that else if... (by TruYadoo)
by codrgi
would this list be safe?
 
the code- Iter1 = mList.begin(); do { if(*Iter1 == m_bAge) { //do code mList.erase(m_bAge) } Iter1++; } while(Iter1 != mList.end()) i'm not sure if it w...
[1 reply] : Not really because when you erase an element any iterators pointing to... (by Galik)
by jham92
high card
 
I am creating a program that asks the user to enter cards and then i need to tell them which on is the highest any help pr advice would be great thanks
[1 reply] : http://www.cplusplus.com/forum/beginner/1/ Sticky at the top of the f... (by cire)
error expected primary-expression before 'else'
 
I still cannot figure out what I am doing wrong. someone commented on it earlier and I did what they said but I am still getting an error. PLEASE CAN ANYONE HEL...
[4 replies] Last: wow I see it now. THANKS GUYS!!! now the only problem I have is the to... (by Joshua Spears)
February 2012 Pages: 1... 2425262728... 64
  Archived months: [jan2012] [mar2012]

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