49,757 Topics
| |
Ok, I have no idea how to make this becuase I need to be able to update the Name & Password database for the Web or somewhere else. Regards | |
Hy everyone ...i need some guidance to make a program.I need to implement NSGA2 algorithm for vector optimization.The optimization function must be selected through a list.And i need to display de Pareto front. | |
can any one please tell me am i done my question right? my question is to store store 1035 to 1265 random in a character array and display the array. and im not sure whats this srand is doing? [code] #include<iostream> #include<stdlib> #include<conio.h> int main(){ srand(1035); char b[30]; for(int i=0;i<30;i++) … | |
Hi, I've recently downloaded MSVC++ 10.0 Express from the Microsoft website, and I can't seem to find a new project template for 'setup and deployment'. Can I download it individually from somewhere? Thanks, Dean | |
i have two questions 1st is can any one please tell me what is the role of setprecision in C++, why it is used? 2nd is : this statement [code]totalS+=sales[i][j];[/code] is equivalent to what, i.e what is the role of this += thanks alot | |
Hi, I have come up with the source code to read files. However, this is source code reads the file 1024 bytes at a time. I would like to modify the code to read it byte by byte. This code wants to determine if 001 bytes ( oo oo o1 … | |
Hi friends, I have an assignment to put three little programs into one, making each one a function of the main program, which is a kind of menu. The three work perfectly as separate entities, but when I put them together, the thing won't compile. Can anyone tell me what's … | |
I want to solve this problem. [QUOTE]There are 52735727364727372 students and 2889221271829121 teachers in a school . On children's day each teacher brings x toffees with him/her . All the toffees are collected and distributed equally to all the students . At the end it was found that there was … | |
Hi developers! This is part of a bigger application written entirely in C++. This is my first time developing an application of this size in C++, and also my first time using the Win32 APIs implementation of threading. So of course I was MEANT to run into errors :). This … | |
Heya peeps, im back with my code of hell. I would like to know if anyone knows the code to create a shuffle button by using the play button and a listview control. My listview has tickboxes, so i imagine it would involve ticking them all and playing them randomly? | |
[CODE]#include <cstdio> #include <cstdlib> #include <iostream> using namespace std; digits() { If(num==1) cout<< "one"; } int main(int nNumberofArgs, char* pszArgs[]) { int num; cout << "Enter a number 1 to 9:"; cin >> num; digits(); system("pause"); return 0; } [/CODE] I just want to make a simple function that when … | |
[CODE]// Cubic conversion of Borwein's Algorithm // Each iteration converges // cubically against 1/pi; // that is, each iteration // approximately triples the // number of correct digits. // Program written by ROBO_HEN5000 // Algorithm complements of Wikipedia. #include <iostream> #include <cmath> using namespace std; int main() { float a; … | |
Guyz, im trying to figure out how to find solutions to there two problems 1. Consider a field which is square in shape and 100*100 units in area . I am standing at the North-West corner of the field . From any place I am allowed to take one of … | |
Getting two link errors with my code provided below They are being generated by lines 38-46 I believe. I can't seem to find an issue... 1>AoE2Wide.obj : error LNK2020: unresolved token (0A000340) "public: static class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> > AoE2Wide::Program::_gameDirectory" (?_gameDirectory@Program@AoE2Wide@@2V?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@A) 1>AoE2Wide.obj : error LNK2001: unresolved external symbol "public: static … | |
I have been looking around a while, trying to figure out at the very least, how to take a string like "25 from a car accident" and have 25 as a useable integer and "from a car accident" as a useable string. what i'm trying to accomplish is doing this … | |
Hello: (I am using Borland C++ Builder 6 Professional) Before you jump all over me I've already read the post Returing Arrays C/C++ and completely understand. For some reason I am still having difficulty implementing in my project. Very brief Project Explanation: I am collecting data from a laser sensor … | |
Hello, Any ideas why this is giving a segmentation fault?: #include <iostream> #include <new> using namespace std; struct List { int A; int B; List *next; }; int main(void) { int llength; llength=1111111111; List *L; L= new List[llength]; L[37370197].B=-37370197; delete [] L; return 0; } Cheers | |
Okay, so I finished the first of a few files on the converting, and I am getting some errors, and yes I have googled them and tried to fix to no avail, I am a noob on programming and am being told to work on a high level project, which … | |
I have the following code witch I have modified with help from Ancient Dragon: [CODE]#pragma warning(disable: 4786) #include <io.h> #include <string> #include <vector> #include <list> #include <iostream> using namespace std; // structure to hold a directory and all its filenames. struct FILELIST { string path; vector<string> theList; }; void TransverseDirectory(string … | |
Hello, I have the following code: [CODE]#pragma warning(disable: 4786) #include <io.h> #include <string> #include <vector> #include <list> #include <iostream> using namespace std; // structure to hold a directory and all its filenames. struct FILELIST { string path; vector<string> theList; }; void TransverseDirectory(string path, list<FILELIST>& theList) { struct _finddatai64_t data; string … | |
Hello, I want to write a function which takes two linked list and check smaller The function CheckSmaller should return 1 if num1 points to a linked list which represents a smaller number than the number pointed to by num2 linked list. Otherwise, it returns -1. If both linked list … | |
I want to create a program that create a file and encrypt it and when the user click the file it will open the program and ask user for password and if the password is correct it will decrypt the file but not save the decrypt file and read the … | |
[code] std::copy (std::istream_iterator<string>(cin), // beginning of source std::istream_iterator<string>(), // end of source std::ostream_iterator<string>(cout,"\n")); // destination [/code] how could I quit from it? besides, if I want to copy partial data from std::ifstream what should I do with the copy algorithm? following code would copy all of the data into the … | |
Hello, this is a newbie question, sorry for that, I am trying to port some Java code to C++. In this code I have a hashmap connecting string values to float arrays of varying sizes. They are specified like this: [CODE=Java] HashMap <String, float[]> hm = new HashMap <String, float[]> … | |
i want to parse a file,my problem is in lines 2,3,4 of each person(every 4line make a person from my class person)numbers of my variables in lines 2,3,4 changed.i want to push_back each of variable in line 2 in a vector until it comes to "\n",i want to continue this … | |
[code]#include "stdafx.h" #include <iostream> #include <string> using namespace std; int _tmain(int argc, _TCHAR* argv[]) { const int Grade1 = 0 ; 29; const int Grade2 = 30 ; 39; const int Grade3 = 40 ; 69; const int Grade4 = 70 ; 100; int Grade ; int i = 0 … | |
Hi all , I am having problem about killing multiple treads in my program at the same time, here is my code: [CODE] int main() { while(1) { i++; HANDLE thread =(HANDLE)_beginthread(TheThread, 0, NULL); if(i==10) break; } Sleep(3000); TerminateThread(thread,0); return 0; } [/CODE] now "TerminateThread(thread,0);" will only terminate the 10th … | |
Error 26 error C2061: syntax error : identifier 'Form1' c:\Users\Black Chocobo\Desktop\WaveMachine\managesongs\WaveMachine\WaveMachine\WaveMachine\WaveMachine.cpp 16 [CODE]// Create the main window and run it Application::Run(gcnew Form1.h());[/CODE] | |
1>c:\users\black chocobo\desktop\wavemachine\managesongs\wavemachine\wavemachine\wavemachine\Form1.h(334) : error C3845: 'WaveMachine::Form1::filePath': only static data members can be initialized inside a ref class or value type [CODE] // the actual music file and its path is kept in the second subItem (of each track) String^ filePath = this->listView1->CheckedItems[0]->SubItems[2]->Text;[/CODE] Any suggestions | |
Hi every body . iam writing a code that reads a line from input file and searches it in test file. but my getline() function reads only the first line and enters an infinite loop i have read many discussions on the topic but still unable to resolve the issue. … |
The End.