Posts
 
Reputation
Joined
Last Seen
0 Reputation Points
0% Quality Score
Upvotes Received
0
Posts with Upvotes
0
Upvoting Members
0
Downvotes Received
1
Posts with Downvotes
1
Downvoting Members
1
0 Endorsements
~913 People Reached
Favorite Forums
Favorite Tags
Member Avatar for airerdem

Hi, I have following code but it is very slow during sorting. [CODE]list<double> fitness; for(i=0;i<250;i++) { fitness.push_back(Random Number); } fitness.sort();[/CODE] Is there any other method about list sorting ? Thanks in advance ico

Member Avatar for mike_2000_17
0
124
Member Avatar for airerdem

Hi, I assigned the name of the file to string vector. I mean when I print the vector, it seems like cout<< files[0]; It prints file.txt and I want to open the file by using vector. I tried ifstream file ("files[0]"); and ifstream file (files[0]); but they did not work. …

Member Avatar for airerdem
0
92
Member Avatar for airerdem

Hi everyone, I have a directory that have 100s of txt files. (Folder is Data_Sets_30) I want to open txt files one by one and get values and close the file and open next txt file get values and close the file and continue like that. I started to code …

Member Avatar for raptr_dflo
0
253
Member Avatar for airerdem

Hi, [CODE]for(i=0;i<10;i++) { for(j=0;j<10;j++) { if() { Now I want to exit from j loop and continue from i loop. } And now if it is wrong I want to continue from j loop. } }[/CODE] Actually I tried break in if statement but it did not help.

Member Avatar for airerdem
0
106
Member Avatar for airerdem

Hi everybody, What I did is, I have 2 one dimensional vector which are inside structure. [CODE]int numberofactivities; struct PopL{ vector<double> RK; //For Random Key }; //Random keys for left population vector<PopL> PopL(3); srand((unsigned)time(NULL)); for (int j=0; j<3; j++){ for (int i=0; i<numberofactivities;++i) { rn=((double) rand() / (RAND_MAX+1)) ; PopL[j].RK.push_back(rn); …

Member Avatar for Fbody
0
173
Member Avatar for airerdem

Hi everybody, I really need that code, I have a text file 32 4 12 13 4 12 0 0 0 0 0 3 2 3 4 and I want to convert it vector or array like A[2]={32,4} B[4]={12,13,4,12} C[9]={0,0,0,0,0,3,2,3,4} The size of the vector or array can be changed …

Member Avatar for Tellalca
0
165