49,761 Topics

Member Avatar for
Member Avatar for ravi_14

IplImage *in; CvMemStorage *storage = cvCreateMemStorage (20506); CvSeq *contours=NULL; CvPoint *PointArray=NULL; for() { //image processing and feature extraction code here cvClearMemStorage (storage); //clear memory area free (PointArray); cvReleaseImage (&in); } At the end of each iteration i ma releasing memory but still i get memory shortage error after # processing …

Member Avatar for rubberman
0
333
Member Avatar for vishalonne

Hello All Tell me who is correct I or my friend void main() { int GuessMe[4]={100, 50, 200, 20}; int Taker=random(2)+2; for(int Chance=0;Chance<Taker;Chance++) cout<<GuessMe[Chance]<<"#"; } I am testing random() in Turbo C++ 3.5 By this code I am always getting answer 100#50# whenever I am executing this code. My argument …

Member Avatar for vishalonne
0
270
Member Avatar for jamesc205

Does anyone know of a compiler that translates a C++ code to MIPS Assembly Language

Member Avatar for mike_2000_17
0
451
Member Avatar for nhiap6
Member Avatar for chubbyy.putto

I am to make a rev op on linked node but somehow i couldnt get to work. I got an error I am kinda stuck right now. The error is in gray Somehow and somewhere doesnt show the reverse link. Can someone show how to do the search node like? …

Member Avatar for chubbyy.putto
0
202
Member Avatar for moaz.amin.37

i have a problem and i can not solve it. Problem is that for example there is an admission form on internet and a student enter his name in digits no dought it is wrong and now here is a problem how to restrict the student that he/she should not …

Member Avatar for Ancient Dragon
0
128
Member Avatar for ايمان_2

It is possible to use any number of characters '/' as a delimiter in path instead of one traditional '/'. For example, strings //usr///local//nginx/sbin// and /usr/local/nginx///sbi n are equivalent. The character '/' (or some sequence of such characters) at the end of the path is required only in case of …

Member Avatar for Ancient Dragon
0
535
Member Avatar for nhrnjic6

Ok, I hope this is the right place for his kind of disccusion. I assume that this kind of question is rather apsurd but I may get killed for this. I have had expirience with both java and c++ but non in field of system programming. I am finishing my …

Member Avatar for deceptikon
0
484
Member Avatar for nitish.mohiputlall

here is the question: The series of numbers: 1, 1, 2, 3, 5, 8, 13, 21, ….is known as Fibonacci series. Each number is the sum of the two preceding numbers. Write a C++ program that writes the first 5 Fibonacci numbers to a file fibnos.txt (in your local drive). …

Member Avatar for vmanes
0
205
Member Avatar for smitsky

I'm trying to understand this function. I try to compile an run it, but it gives an error message at line 12. Thanks. #include <iostream> #include <string> #include <cmath> using namespace std; int stringConvertInt(string raw) { int sum=0, power=0; power=raw.length()-1; for(int i=0; i<raw.length(); i++) { sum=sum+(pow(10,power)*(raw[i]-48)); power--; } return sum; …

Member Avatar for smitsky
0
230
Member Avatar for moaz.amin.37

i have a problem that how to concatenate more than two string in operator overloading i write a code but it is not run #include<iostream> #include<conio.h> using namespace std; class count { private: char str[50]; public: count() { str[0]='r'; } void input() { cout<<"Enter string = "; cin.getline(str,50); } count …

Member Avatar for moaz.amin.37
0
511
Member Avatar for nitish.mohiputlall

My program displays the details of 2 students. name id address module code and module marks. my program works well but the problem is when i enter the details of the 2nd student i am not able to enter the name as if it skip this first part and go …

Member Avatar for StuXYZ
0
149
Member Avatar for waleedahmad

Here's a little program i wrote, i'm trying to pass my structure book to function input. The code works fine on Code::Blocks but VS12 is giving an error on compliation " error C4700: uninitialized local variable 's' used ". What i'm doing wrong? #include <string.h> #include <iostream> using namespace std; …

Member Avatar for Ancient Dragon
0
2K
Member Avatar for MaidaKhan

The insert function int the arrayList is not working...d[count] = v is giving garbage.I am unable to find the problem.Can anybody please help. class ArrayList { private: int count; int *d; public: ArrayList(int size=2) { d=new int[size]; count = 0; } void insert (int r) { d[count] = r; count++; …

Member Avatar for iamthwee
0
119
Member Avatar for MaidaKhan

This fuction of insert in descending order is not working.Can't find the problem.Can anyone help? class LinkedList { private: class ListNode { public: int data; ListNode *next; ListNode(int d) { data=d; next = NULL; } }; ListNode *head; public: LinkedList() { head=NULL; } void Inorder(int d) { ListNode *tmp = …

1
89
Member Avatar for Jamie_3

#include <iostream> #include <conio.h> using namespace std; int main(){ char command[1024]; char newchar; cout << "Command Line Interface Test with Intellisense" << endl; cout << endl; newchar = _getch(); command = command + newchar; } My Code. It doesn't work. `command = command + newchar` has a problem. Please help.

Member Avatar for vmanes
0
774
Member Avatar for mohanned_1
Member Avatar for Shehroze
Member Avatar for Shehroze
0
252
Member Avatar for mc3330418

I have a text file below that I read from. 0123456789012345678 IN NUMBER LOOP LD NUMBER BZ LPEND LD TOTAL ADD ONE STO TOTAL LD ZERO SUB NUMBER BGTR ENDIF BZ ENDIF LD POSITS ADD ONE STO POSITS ENDIF IN NUMBER B LOOP LPEND LD POSITS MPY HNDRD DIV TOTAL …

Member Avatar for mc3330418
0
297
Member Avatar for ravi_14

i am not able to connect to the sql server on my system. SqlConnection^ connection=gcnew SqlConnection(); connection->ConnectionString ="Data Source=blueboy\sqlexpress;Initial Catalog=DCV_DB;Integrated Security=SSPI;Pooling=False"; i got the string from database properties.(i have attached the same in this post) sql service is running. tcp ports are enables too.

0
113
Member Avatar for thief420

Please help me with this error. Thank you in advance [Linker error] undefined reference to `Simple_window::Simple_window(Point, int, int, String const&)'

Member Avatar for Ancient Dragon
0
41
Member Avatar for agrbinoo.albaker

Write a complete C++ program that reads the attached file (values.txt) to find and print the following: a. The average value of the numbers in the file. b. The maximum and minimum value c. The count of negative and positive values (ignore zero) #include <iostream> #include<fstream> using namespace std; int …

Member Avatar for Moschops
0
171
Member Avatar for Reem_1

I tried all possible test cases and It outputed the correct answer , I wonder why UVA doesn't accept my answer <#include<iostream> #include <stdio.h> using namespace std; int main() { int i, j; unsigned long long int tempI, tempJ; int maxCaseLen = 1; int count = 1; while (scanf("%d %d", …

Member Avatar for Reem_1
0
630
Member Avatar for daniel1977

I am getting an error in the header file: class linkedStackType: public stackADT<Type> Can you see anything wrong with what I have, and why the compiler is complaining about "stackADT"? I would love it if you could give me some insight into this matter. Right now I'm only concerned about …

Member Avatar for mike_2000_17
0
211
Member Avatar for phony

// This program uses the a queue template to create a queue of strings. #include <iomanip> #include <iostream> #include <cstdlib> using namespace std; // // TO CREATE A "template" class named "T" template <class T> // // TO CREATE A CLASS NAMED "Dynque" class Dynque { private: struct QueueNode { …

Member Avatar for phony
0
299
Member Avatar for dudicus14

{file has 1000 lines that look like these 114680858 19670607 Matilda Vincent MI 114930037 19471024 Desdemona Hanover ID 115550206 19790110 Xanadu Perlman ND 116520629 19630921 Alexander Hall SD 117050976 19301016 David Lamprey GA 119610646 19650202 Thomas Porlock IL 120330928 19621126 Cary Cartman NC struct employees { int ss_number;//social security int …

Member Avatar for vmanes
0
144
Member Avatar for Labdabeta

Hello, I have a bug in my program somewhere and I cannot understand why. The program merely prints data from a binary file. Here is the code: #include <iostream> #include <fstream> #include <vector> #include <cstdint> using namespace std; int main(int argc, char *argv[]) { if (argc!=2) { cout<<"Invalid argument count, …

Member Avatar for Labdabeta
0
410
Member Avatar for inspire_all

i am trying to overload +operator to concat 2 strings i tried to write a code but it is giving 2 errors and i am also not sure whether logic is correct..MY CODE is [CODE]#include<iostream.h> #include<conio.h> #include<string.h> class string { char *str; public: string() { cout<<"enter string"; cin>>str; } void …

Member Avatar for Ancient Dragon
0
2K
Member Avatar for maisara

I hve sme doubt in pseudo code I hve created da flow chart and c++ code but I need to create pseudo code I dnt no hw to create it Becz da flow chart hve 2 inputs such as cot=0, ans='y' And 5 option such as add inquiry , view …

Member Avatar for vmanes
0
279
Member Avatar for Auroch

Hello, I have the following problem: Entering coordinates of points on a plain with keyboard (as rows x,y). Analysing this coordinates. Replacing coordinates in vector (point - structure data type). Then calculating distance from the first point to all another points. I've written the code of this problem using arrays …

Member Avatar for Auroch
0
2K

The End.