General C++ Programming - April 2012 (Page 12)

string to integer conversion
 
I was trying to convert a string to integer but i am facing problem with it. I tried using atoi, strtol and stringstream. All the three methods are giving error...
[4 replies] Last: Thanks... My compiler did not support stol. But i converted the strin... (by nilagayu)
by Mannah
2 dimensional array in classes
 
I need to create a matrix class of 2D array....is the following code correct #include <iostream> #include "matrix.h" using namespace std; Matrix::Ma...
[1 reply] : No this code is not correct. The problem is in the copy constructor ... (by vlad from moscow)
Base conversion so confused ? help?
 
THis is my code so far how can i do base conversion to any bases between 2 - 16. I don't really know how. Could i use this ...
[3 replies] Last: yes i get 24 / 2 = 12 remainder 0 12 / 2 = 6 remainder 0 6 / 2 = 3 re... (by code builder)
How add the pkg-config option to bjam in boost libraries
 
Dear friends, I am compiling my one module program by using the following command gcc -g -o `pkg-config --cflags glib-2.0 dbus...
[4 replies] Last: yes , that pkg-conf only . (by BABU Prasad G)
structure
 
struct node { int data; node *next; }; struct node* sortedmerge(struct node* node1, struct node* node2) { struct node* merging = NULL; counter+...
[no replies]
To display a bitmap image in c or c++ using progressive scanning aka non-interlaced scanning or de-interlaced scanning
 
Progressive Scan to display bitmap images? hi i need to know how to display images using progressive scanning.. . i.e, i need an algorithm & program in c or c...
[no replies]
how to display a bitmap image in c or c++ using Interlacing aka interleaving?
 
to display a bitmap image in c or c++ using Interlacing aka interleaving? hi i need to know how to display bitmap images using Interlacing aka interleaving.. ....
[no replies]
Quicksort using pointers to a BST
 
how could I implement this integer quicksort into a auxiliary array of pointers quicksort? void QuickSort(int A , int FirstIdx, int LastIdx){ int PivotI...
[1 reply] : how could I implement this integer quicksort into a auxiliary array o... (by coder777)
A program in an Array
 
Someone help me program in C++ to read five elements in an Array known as Original and then store the elements in reverse order in another Array Reverse . Disp...
[1 reply] : http://cplusplus.com/forum/beginner/1/#msg6680 (by R0mai)
Linked List Unhandled Exception
 
Hello! I am getting an unhandled exception error with my appendNode function for my linked list. Can anyone help? Thanks! #ifndef NUMBERLIST #define NUM...
[1 reply] : I'll give you the same advice I gave someone two days ago. http://cpl... (by TheDestroyer)
Creating columns from a text file
 
I am having a bit of trouble with my last program I have to write. What I am asked to do is given a text file with students information, I am to output each stu...
[3 replies] Last: By using '\t' (tab) rather than ' ' (space) you can line up columns (by buffbill)
Problem with Substring
 
In this code I am supposed to enter a 5 character inventory code. The inventory code has a color associated with it and I am supposed to be able to use substr ...
[1 reply] : why is this duplicated ? cout << "Enter five-character Inventory code... (by buffbill)
string problem
 
Now i am learning <<c++ primer>>,i ran into a problem. Please do me a favor. question: Operators return left operand as results.So we can put some inpu...
[no replies]
Including header files
 
This is some of my program. My problem is when i try and include my header file "additional.h" i get the error message: 1>c:\users\aaron\documents\visual st...
[2 replies] Last: Well due to carelessness on my part, and intelligence on your part tha... (by Garchimo)
Program not recognizing if statements
 
For some reason this program isn't recognizing the if statements I put in setPricePerYd...I can't figure out why that is. Any help would be great! // This...
[1 reply] : Tabs have no effect on if statements unlike other languages. You can o... (by closed account o1vk4iN6)
Deallocating my constructor memory
 
So I have the following in my constructor: Queue<T> *newQueue = new Queue<T>; ...// do stuff not involving newQueue items = newQueue; Now I need to...
[1 reply] : I assume items is some kind of container that is owned by the class.... (by Disch)
Help with why program isn't working correctly
 
Now that I have fixed the strings...why isn't the program figuring out the math properly? I think that it is not calling the pricePerSqYd correctly, but i'm not...
[2 replies] Last: Oh, thank you! (by KaraPardue)
by chemy
2 player NIM c++
 
So i'm studying for my final and going over problems in the book. i missed the class so im lost. ive done this far, but i can't really figure out after this. ...
[7 replies] Last: I'm also trying to complete this exact program for class. But I'm havi... (by Kleinbird36)
Help with Answer Key program
 
So i was given an assignment with some unusual parameters. My teacher likes to add difficult objectives to make the code longer (really just to be evil) and thi...
[1 reply] : I know this is alot but ANY help will be great. please and thank you (by flan8849)
Please help me with this quick assignment!
 
My professor has given me a code file and a data file, and I need to alter just line 64 "if (p1->count > p2->count) {" to sort alphabetically instead of by coun...
[15 replies] Last: You're using the console and it only scrolls back so far? (by cire)
April 2012 Pages: 1... 1011121314... 49
  Archived months: [mar2012] [may2012]

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