General C++ Programming - August 2011 (Page 21)

runtime: writing/reading datafile VS allocating storage for huge matrices
 
Dear all, I am going to write a program that has to calculate with huge matrices (sometime sparse, sometimes not) of size than more than 10.000 x 10.000 There...
[no replies]
by Chathu
Call By Value And Call By Reference ...This Code Isn't Working .
 
Hi. Can Someone Plz Help With This Code. It Gives A Error When I compile It. Cant Figure Out What The Error Is:( I Use Dev c++ BTW #include<iostream> usin...
[2 replies] Last: Thanks :) (by Chathu)
SDL String Input Problem
 
After my second term of C++ programming I thought I had finally escaped the clutches of SDL, turns out it reared its ugly head again. I have used SDL before but...
[4 replies] Last: Also, i just went ahead and took out the code that disables unicode, s... (by darkhorse)
2D Pathfinding, need help
 
Hi guys I've been making a simple game of pacman using c++ and SFML. Currently I have the map, Pac-pills, Pac-man, Movement and Powerpills in the game all worki...
[6 replies] Last: The link eraggo posted has an example in it. Again, you could do it w... (by hamsterman)
Pulling from a dif file
 
In short I want to have a list of names in a .txt (or whatever) file and pull from a line number. In my prog I got random to pick 3 dif numbers. From those n...
[2 replies] Last: Meh. I've seen worse. Much worse. (by helios)
Pure Virtual Error, Please Help!
 
I am trying to get both PersonType class and EmployeeType class to be abstract and the pure virtual method is to be overiddin in the derived classes. Here is...
[2 replies] Last: Remove bolded part: //virtual char PersonType:: GetType(void) = 0;... (by savavampir)
by rain
wstring to char* problem
 
Does anyone know why I get only 1st char of title and not full title? I need to convert that title to char * becauseI want to use it with lua_pushlstring to ...
[4 replies] Last: Do you know the difference between the ANSI char set and the UNICODE c... (by andywestken)
benchmarking code
 
hi, I am trying to write a benchmark program that takes about 20 minutes to complete because the actual functions needs to be called plenty(unknown variable) t...
[2 replies] Last: does that mean something like this (mtime>1000)?cout<<"elapsed tim... (by itcplpl)
by Adarsh
Data structures in c++ stl
 
Are there any built-in data structures for avl trees in c++ standard template library? What sort of data structures are supported in stl?
[2 replies] Last: no i dont think . we have Binary tree BST and heap that create on arra... (by ahura24)
by mido22
how to sort arr in struct
 
i have struct mido { int wage,boss; }; arr .wage=5 , arr .boss=0 arr .wage=2 , arr .boss=2 arr .wage=4 , arr .boss=1 arr .wage=3 , arr .boss=0 arr...
[4 replies] Last: if you want use STL and write a general code you need define first you... (by ahura24)
General question about includes
 
Hi everyone! I've been searching for the solution to the following question for a while with no success. Hopefully you will be able to help or clear me out. ...
[3 replies] Last: The only way to accomplish this would be if mylibrary.h does not inclu... (by Disch)
Question about deleting
 
fist, if i specify memory with new operator to a pointer and i don't free the space with delete operator, what will be the result? will i get an error later? o...
[1 reply] : if i specify memory with new operator to a pointer and i don't free t... (by Disch)
External Linkage Leakage in C++
 
Can someone here please explain what is the external linkage leakage in C++? Thanks.
[1 reply] : Basically what it means when someone uses the extern keyword is that... (by Albatross)
by sae
problem with consecutive numbers
 
Hi I have been trying to generate consecutive numbers from 0 to 16 without a for() (I can't use the for because the hardware I'm working with doesn't allow me t...
[4 replies] Last: does your hardware support goto label: code here; got... (by closed account zwA4jE8b)
A faster algorithm
 
#include<iostream> using namespace std; int main(){ int n, *tab; long long int cur = 0, max = 0; cin>>n; tab = new int ; for(long int i=0;...
[7 replies] Last: What is the algorithm common with that I have written in my first pos... (by Syuf)
how to know the size of a struct
 
I have some problems,please help me ,thank you..... I want to know the size of some structs by their name. But , I read the name from a txt and the type of the ...
[6 replies] Last: thank you very much!.... I got it! (by zhenglian li)
Copy C`tor and operator=() implementation
 
Hi, i need some help with Copy C`tor and operator=() implementation, i don`t know how to implement operator=() with copy ctor when i have array of Customers*. ...
[6 replies] Last: thank you man, it was very helpful :) (by aymanbah)
Unsigned Characters ,strings
 
Please help me with this program ,i have a final exam tomorrow and i literally don't know whats going to happen. #include<stdio.h> #include<conio.h> stru...
[1 reply] : This code plays a lot with bit order. It would help to write down each... (by hamsterman)
by ms4800
passing a file object as a const reference
 
hello void compress::makeDict( ifstream &fin) { string word; while(fin){ fin>>word; cout<<word<<endl; ...
[4 replies] Last: While reading you change the get pointer position. (by Syuf)
by rudy01
boost filesystem question
 
Hello all, I am trying to use the "path" and "copy_file" functions of boost filesystem in C++, and they work fine, except for cases when there are hidden file...
[1 reply] : You might want to ask this question in the Boost mailing list/forum (I... (by helios)
August 2011 Pages: 1... 1920212223... 29
  Archived months: [jul2011] [sep2011]

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