Beginners - October 2010 (Page 10)

by heidiK
Vector duplicates removal
 
Hello Everyone. Could anyone please help me quickly find duplicates in a vector of over 60000 records. It takes a loooootttttt of time ;'(. Here's the code. ...
[1 reply] : Hello heidiK, try using std::sort and std::unique. (by coder777)
by MJDB
comparing vectors (vector out of range)
 
Hello there I have been running to this problem over and over and don't seem to find what should I do. I have two vectors: vector<int> vb(5); vector<int...
[1 reply] : For your second one, vector::erase() invalidates iterators, so it1 wil... (by Albatross)
Transfer results from different classes into one class by reference?
 
I have: - 1 class to read a data series (series.h and series.cpp) - 1 class for a function (function.h and function.cpp) I'm trying to create another class w...
[2 replies] Last: Thanks for your reply These are the errors: integral.h|16|error... (by thecatalyst)
How to set folder attributes!
 
Hay i am a absolute beginner in C. so i was trying to make a program which will make a folder with system hidden attributes. the program i use to create a fold...
[1 reply] : On Windows you can use SetFileAttributes function: http://msdn.microso... (by Null)
get position
 
hi guys, I'm trying to get a word position from a binary file, I have a program that searches for the word, and finds it. Do you know of a function to get t...
[4 replies] Last: It really isn't an algorithm yet, I'm still working on that, it's in S... (by claudiordgz)
Visual C++
 
If you know the basic grammar of C++ fairly well, taken in consideration that your still new. Is it easy to learn Visual C++. Im asking this because I was just ...
[4 replies] Last: I ment Windows programming... the code likes like this: #inclu... (by Analyzer)
An input format question
 
hey there, I've run into somewhat of a dilemma. for a practice program I'm writing, I need to input the size of an array and on the next line, I need to input t...
[4 replies] Last: You really didn't need to to that. Not that it matters.. By the way, a... (by hamsterman)
converting BOOL to INT
 
how to convert this if (!charInWord (input_2, size2, *p)) ... ... bool charInWord (CharInfo *input, int size, CharInfo& temp) { CharInfo *p = &i...
[8 replies] Last: You said you needed a function that takes a pointer to char and a char... (by filipe)
code on struct
 
struct my_struct { int val; } my_array ; What does the my_array do?
[1 reply] : It creates an array of 100 my_structs called my_array. (by Athar)
Why is the answer always zero?
 
This is a textbook project, but isn't a school assignment. I've included a comment within the program that describes the expectations of the project. Why ...
[3 replies] Last: OK, it seems to work now. Thanks to Athar. I also made some chan... (by khouser)
by blgblg
calculate the remaining time
 
hi i need the function which can say how much time remain to the last date. the last date is input,i mean the last date is given to code by user,and this fun...
[2 replies] Last: thank you but i cant understand this functions. which function can ... (by blgblg)
by Rave
Trouble with spliting files, (header files, etc)
 
Hello, I am trying to learn splitting files and making header files and such, thus i wrote a small program for the purpose of learning how splitting files...
[3 replies] Last: er... you don't have to make a makefile. Just add Driver.cpp as part ... (by Disch)
Unexpected error?!
 
Hello everyone,i wrote the following code where there is a function which ads two object of class type.In order to have acess in the private members of the cla...
[3 replies] Last: There is a big difference between Visual Studio 2006 (does it even exi... (by Athar)
by Rave
Problem with pointers
 
Hello, In the process of writing code, i am at a troubled situation. The problem has to do with pointers. Here is my code:: ( i know you might thing th...
[4 replies] Last: Thank you so much, i understand now, i been misinterpreting a lot of t... (by Rave)
call main of a header file in another
 
in my header file there is a function which is called in main. i want to call main in another file, how can do this?
[3 replies] Last: thanks for you. actually i have a multi-threded code, one of the thre... (by adamger)
a template function promble!
 
I defined a template function call PrintSetBtIterator as show in the following source code , the code seams to be correct , but the commplier just give me so...
[3 replies] Last: The syntax identifier1 :: identifier2 when parsed by the c... (by jsmith)
How the memory is allocated?
 
Hello everyone! I have readed that the memory of a program is divided in four areas: 1.code,2.global,3.heap,4.stack. First I would like to ask if the code a...
[2 replies] Last: In the first question i suppose the no goes to "if the code area conta... (by kikirikou)
by rej3kt
changing the variable names in a class.
 
I changed all the names in my class but I've done something wrong now and I can't figure out what it is: #include "car.h" #include <string.h> Custome...
[13 replies] Last: Thank you mate I appreciate all the help, everything is fixed now, you... (by rej3kt)
change output look
 
hi.. i try to make a line editor in c++.. So i want something to change the letters.. for example when i run tha file i want to show me this.. 1> Hello my frie...
[3 replies] Last: i think this will help http://ss64.com/nt/syntax.html (by Mazd)
Problem with array of string from uppercase to lowercase
 
My code is posted below. The code takes the entire string the user inputs and converts everything to uppercase (posted code works with no errors). I am trying t...
[6 replies] Last: Note that while(str ) is the same as while(str != 0) ... (by hamsterman)
October 2010 Pages: 1... 89101112... 42
  Archived months: [sep2010] [nov2010]

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