49,761 Topics
| |
Hallo! I've been having some trouble getting a save/load function to work properly. I'm trying to save object and their properties to a file in binary using fstream. And then being able to load the object from the binary file the next time im running my project. Quick breakdown: I … | |
hello, I wanted to ask you all a question. suppose that my c++ program has read from a text file a set of characters like the one below using the command inData >> temp. i output the characters of the text file and stored all the characters in a string … | |
Hey all , I'm writing a Windows program & i'm having a very silly and annoying problem. I Create a very simple Dialog(It's a window actually) with one text box and one button , then i try to use SetFocus() function to Give the focus to the text box so … | |
this code is for bessel function Y n (x) 2nd kind I'm in the level 4 at computer engineering my prof. gave me that assignment , I want help to improve it to get an accurate results thanks! | |
OK, here is my dilemma, I am trying to read an input file into 3 arrays. The file must be formatted as such (ie - with each value on a new row): 3 - n value for an n x n matrix 'a' 1 - a11 - Next n^2 terms … | |
tell me code for designing a simple text editor using C++ with open,save,save as,like other options.. | |
Hi all, bit of a c++ newbie and hoping you might be able to help me with a problem. I'm trying to calculate the elapsed time between two dates using difftime, however I keep getting an elapsed time of 0. Can anyone see where I'm going wrong? Any help greatfully … | |
why i cant run graphics.h in turbo c++ but i have graphics in my llibrary :( help plss | |
Hello, I have been working on this program for the past four hours and was doing good till I got to this point. I am pretty sure that I probably can't do it this way, but I'm just learning and it isn't becoming apparent to me how to correct it. … | |
when i try to use pow with cmath header i get error message pow(int,int)is ambiguous it also gives other possible options i.e pow(double,int) why is int^int ambiguous? how could it be less ambiguous? | |
hi every body>>>> please i am student and this my homework very important to me the question is : how to complete this simple program to make its return 0 ????? the answer is some thing instead of: [CODE] /* some statments */ [/CODE] please i am new here and … | |
I need your help... Again... How can i combine reading from file with [iCODE]std::getline(file, std::string);[/iCODE] and [iCODE]UpdateData(FALSE);[/iCODE] ? UpdateData() accepts only CString and getline only std::string, and then i try to use it like that: [CODE]std::string readbuff; int length; std::ifstream file("file.txt"); while(getline(file, str)) { length = str.length(); for(int i=0; i<length; … | |
hi, beginner question i am planning to write code for different values of a^b. both a and b will vary in the program and both will be long long ints; as my compiler wont allow pow(int,int) as it is ambiguous(dont know why) either while have a as a double and … | |
trying to write a fuction to work out the GCD of two numbers seems to run ok but the return is incorrect any help much appreciated #include <iostream> #include <cmath> using namespace std; int g_c_d(int a,int b); int main() { cout<<g_c_d(2871,4060);/*test example*/ cout<<endl; system("pause");/*been advised not to use this but … | |
[code] how can we check that user [B]inter [/B]an [B]integer[/B] or not? [/code] | |
I'm new to C++ and I'm having trouble understanding how to determine what to put inside a loop. I know it differs from program to program, but a lot of my assignments deal with the user inputting a number of how many numbers they want to input (it can be … | |
there is a mistake on the code. I would like to write "test" like t e s t but it writes reverse. it is easy but my brain is not enough. [CODE]#include <iostream.h> #include <string.h> #include <conio.h> int main(void) { char *pointer="test"; int index; for(index=(strlen(pointer)-1); index >= 0; index--) /* … | |
Hi, Java has been my choice programming language for many, many years now, and I want to start doing C++. I've written in C++ before, but that was a while back. I'm treating myself as a beginner at the moment. I use Eclipse to write Java, and I recently updated … | |
There's a header class called example.h [CODE] #ifndef __Sample_H__ #define __Sample_H__ namespace example { namespace Samples { class AlgorithmSample { public: virtual void release(void) { delete this; } virtual boolean process(void); }; class AlgorithmDesc { public: virtual String getName(void) const { return "some example program"; } }; }; }; #endif … | |
// The purpose of this Lab is to start the program used in Lab 1 and modify it // to calculate the average of 4 grades entered by the user and display the results // on the console through the use of the math operators in C++. // Part 2 … | |
When under Windows 2008 Server with my C++-program (with a cicle) many directory are copiing, then the memory is increasing and remain at a high level. Waht can I do? | |
like a Picasso's present return to natural memory | |
I'm trying to sum command-line integers. My total is constantly 473. I dont know how to get the right total. [CODE]#include <stdio.h> 4 #include <stdlib.h> 5 #include <ctype.h> 6 7 #define MAX 100 8 9 void sum(char *a, int n); 10 11 main (int argc, char *argv[]) 12 { 13 … | |
So i guess its easy enough to encrypt text, but what if you wanted to encrypt a video file or some other file that wasn't text? By writing my own program I mean. How does that work, any links? Thanks | |
When to use pointers and when to use references in c++. plz clear my doubt.. thnks in advance | |
I need some help, I have created a text box and a button, how do I handle the data, like... what do I have to put inside the button case and what to output the data? I have tried so far... [CODE]case ID_BUTTON: { // code const int size = … | |
I just learned class and object today, couldn't even get the code compiled. could anyone help please? Thank you I have three files: Product.h Product.cpp TestProduct.cpp We haven't learned to put everything in a project yet. so for now, just just these three source files. [CODE] class Product { private: … | |
Hello I used 2 linked list. First : Students. Second: Doctor. Every Doctor takes a set of his students. The problem : How do I add students to the doctor? [CODE]#include <iostream> using namespace std; #include <string> struct student { string name; // current name student *next; // pointer to … |
The End.