General C++ Programming - April 2010 (Page 17)

How to convert int to a const char?
 
Well I want to display message to my SDL program, and I want it to be an interger that keeps changing. Here's what I have offcourse its wrong somehow I have to ...
[5 replies] Last: actually this code works, I just put the whole thing in a loop. I had ... (by Kondziu)
using data files
 
I am trying to write a program that has a .txt file. It includes 4 names, 4 pay rates and the hours they worked. I have to use the file and import the data and ...
[no replies]
What's next?
 
So i just finished my c++ book,and i'm wondering what do i do next? Everyone says i should get another book,but they're all pretty much the same. I'm pretty l...
[1 reply] : Think of C++ as merely a tool (because it is). If you're not making or... (by helios)
Kruskal's Algorithm
 
/************************************************************ -> This Program is to implement Kruskal algorithm. -> This program is to find minimum spann...
[2 replies] Last: Very good explanations, and yes, I agree this code is horribly written... (by John Linux)
by samnet
UTF-8
 
have that Java's Charset.forName("UTF-8") in c plus plus?
[no replies]
by vonpik
Problem with reading big amount of numbers from file Pin
 
Hi! I have to do a project for my studies. It is a insertion algorithm. I'm reading data from file with using vector. then I'm copying vector to a normal arra...
[3 replies] Last: If you were to do this using dynamic arrays, you'd just end up impleme... (by helios)
by mayarb
problem with math fanction
 
hellow, i have problem in my code, The general purpose of this code is to describe a random motion of particles in squre plane. theta=rand()%6283; //...
[7 replies] Last: hi helios, actually your advise help me a lot and it's work better no... (by mayarb)
Exception from a different thread
 
Hi, I made my own kind of library for my application to be able to use the winapi in a more OO and clear way and just to use some algorithms. But I have an o...
[1 reply] : An alternative would be to make the function synchronous and to implem... (by magnificence7)
Pointer Data Corruption?
 
Hello, I am working on a simple program that declares two DynamicInt class objects in the driver, one with an argument and one without. Included in my imple...
[2 replies] Last: Thank you, I forgot that I had to create the pointers using the 'new... (by GWalk612)
Binary Trees
 
Hello Everyone! I am currently working on a program that allows the user to select from a menu of options. The options include: insert a node, delete a node,...
[3 replies] Last: Hi, here is a corrected version of the function, calling it should ... (by TheBear)
by wrz234
can pls check on my code??
 
i want to declare variable char on 'p' or 'a'. So i wrote like char zone = 'a' || 'p'; is that correct?
[6 replies] Last: i will try using the exam u gave, because i still encounter problem w... (by wrz234)
by jt1991
what error i did??
 
#include<iostream> #include<iomanip> using namespace std; void getdata(); void grade(); const int sentinel = 1000; int i; float rslt; struct stud...
[4 replies] Last: ok thanks (by jt1991)
query on priority queues
 
hi. i have an array if integers like 1 1 2 5 5 6 and i want to assign priorities to them like a has e heighest priority followed by a then a then a then a ...
[no replies]
Hello, I having trouble solving this syntax error.
 
#include <iostream> #include <iomanip> #include <string> using namespace std; class Bot_warrior { public: Bot_warrior():height(78), weight(190), wea...
[2 replies] Last: I will code tag for now on. Thank you for your time. (by marty09x)
How can i make C++ wait? with out stoping other functions? (1,2)
 
ok so I use Sleep(); and it sleeps all my functions. What if I just want it to Sleep(); the function that I put sleep in, so the other functions wont get slept?...
[30 replies] Last: There's refresh rate at an earlier stage. Specifically, how often the ... (by helios)
Use of private nested types as return value of private methods.
 
Hi, i am trying to write a container, namely a red black tree, but i can't figure one compiler error out. Here is my situation: Header: #ifndef REDBLA...
[7 replies] Last: Thanks to both of you. (by TheBear)
by maikel
static const reference to std::cout
 
Hey buddies, is something as this possible? Caution! This is invalid code: #include <iostream> #include <string> template <typename T> struct V...
[1 reply] : You need to define a static member outside the class declaration: ... (by Bazzy)
by wrz234
Change time format
 
Can guide me how to change the time format if i input 5.45pm and the output will display 17.45 hours. Pls help
[3 replies] Last: pls help on my code, when i input 6:45p .. the output show only '6 45... (by wrz234)
by wrz234
exit
 
#include <stdafx.h> #include <stdio.h> void main() { int hours = 0, rate = 8; double salary = 0.00; do { printf("Enter number of...
[6 replies] Last: Thanks duoas i had make it done with your ref. (by wrz234)
no matching function for call error C++
 
Hi, I have a vector class vec . Now, I am creating custom utility functions using function templates . For example, template <class T> T sum(vec<T> &v...
[5 replies] Last: Awesome! thank you very much. Yes, it solves the problem... 1 less pr... (by pozdrav)
April 2010 Pages: 1... 1516171819... 24
  Archived months: [mar2010] [may2010]

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