General C++ Programming - May 2012 (Page 10)

how to create a queue in c++?
 
the kind of program that i actually want to write is:there are different data that comes in from a server and we have to send that data to another server,and am...
[1 reply] : Um... would the normal STL queue work for your purposes? http://www.c... (by Albatross)
Tax program
 
Having some problems getting this code to do what I want it to do. I can get it to perform some of it correctly. But the main problem is 2 fold. First I need to...
[9 replies] Last: You never show updated code, so nobody really knows what you're talkin... (by cire)
New to C++ please help
 
HI there, I'm totally new to C++ . In a homework i have given the assigment to find the ASCII code for some characters. for example Caps A = 65 Now, in a que...
[3 replies] Last: Thank you very much for your help. I really appreciated. (by scout51)
Pass by reference to pointers
 
As I understand, pass by reference to pointers is another way to pass arguments; it's supposed to be cleaner than pass by pointers to pointers (since compiler d...
[3 replies] Last: Not the only issue of course. newNode is already a pointer, so lines ... (by Cubbi)
Bubble Sort and Insertion Sort
 
#include <iostream> #include <cstdlib> #include <ctime> #include <string>//swap function predefined. Not Used ( optional ) using namespace std; void printAr...
[2 replies] Last: Yes! Thanks. But when I read about the Bubble Sort, they Say is superi... (by closed account SGb4jE8b)
Dev C++ GLUT not compiling
 
I am programming in a Linux Operating System, if that changes anything (I'm using WINE just to get my compiler started). Dev C++ (5.0.2.1) is my compiler. I m...
[1 reply] : Sorry, I had a wrong version of the library. The program now works pe... (by Twist177)
occurrence of string cg in a dna string
 
hi, i am new to c++. i want to write a program to find the sequence of cg in a dna string. i know we have to find the length and use the loops but i am really c...
[4 replies] Last: thanks (by kalicha)
pointers and adresses
 
Shouldn't this code print the same adress for p.fillim and h.begin? struct programet { int ID ; char * fillim; char * fund; } ; ...
[4 replies] Last: so if i print cout<<p.fillim<<h.begin<<endl; i'll have the same ou... (by Silvia 22)
by Laveer
minimizing a form
 
How would I minimize a form? Rather an application itself? You can exit it by using " Close(); ", though is there a command for minimizing? I'm making a border-...
[no replies]
Streak counter
 
I am making a maths program and i need to show the longest streak of correct answers and also the longest streak of the incorrect answers. how can i do this? I ...
[8 replies] Last: oh lol, I nvm, I missed one thing. I misread, my bad :P I read it as... (by Splux)
Fif Game in C++
 
(This is my first post on this site. I don't think this question was already answered) Fif Game: 9 squares labeled 1-9. I'm taking turns against the computer...
[no replies]
Clarify passing ptrs to ptrs vs pass by ptrs
 
I thought I understood passing by ptrs to ptrs (pointers to pointers) vs pass by pointers, but now I'm not sure. Below are the same function that clears an arra...
[8 replies] Last: This does not work because you pass incorrect type to the function. ... (by vlad from moscow)
queue
 
why it is print just last node were add #include <iostream> #include <string> using namespace std; struct personal_rec { string name;...
[3 replies] Last: Your problem is that you call enqueu with arguments (rear, front), but... (by doug4)
compiling
 
I am trying to compile this simple code: #include <iostream> using namespace std; #ifndef Bank_Acct_H #define Bank_Acct_H class Bank_Acct { public: Bank_Ac...
[1 reply] : #include Bank_Acct.h should be #include "Bank_Acct.h" Are you sur... (by Peter87)
Infinite recursion in Merge Sort
 
Hi, I'm trying to implement a merge sort as follows: // Merge sort //lb = lower bound, ub = upper bound, temp = temporary array, data = input array //Maxim...
[2 replies] Last: Thanks BlackSheep. You are right. But how to go about it then ? Any su... (by indyarock)
by xillah
creating a class called date and a child class called time
 
Hello everyone, I am trying to learn c++ and I am having a very hard time understanding this problem. I am supposed to create a class called date that has th...
[6 replies] Last: To solve such problem you need some basic understanding of OPP in C++ ... (by therockon7throw)
Reading a png
 
Does anyone know how to read a png file into an int array of its pixels? I've come from Java and there's a BufferedImage.getRGB() method there for exactly what ...
[3 replies] Last: The sample code you've shown there isn't C++. Looks like some kind o... (by Moschops)
sorting vectors
 
Hi guys, i need help in sorting vectors according to criteria. This was a boolean comparator function that i wrote to sort array values in descending order. Ho...
[2 replies] Last: I see. Thanks for your help =) (by CLearner88)
Linked list
 
hi guys,i just wanna know that how you can access nested class data members like in my this code.this is my working code with one operation of adding new record...
[1 reply] : "Node" only exists in the context of "linklist", so to access it, you ... (by Gaminic)
Qt and Static linking Help
 
Hello i am new to qt creater which can be found here http://qt.nokia.com/. The problem i am having is that the program that qt makes depends on dll that are par...
[2 replies] Last: You can't static link a dll. A dll is a library specifically made for ... (by Moschops)
May 2012 Pages: 1... 89101112... 41
  Archived months: [apr2012] [jun2012]

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