49,761 Topics

Member Avatar for
Member Avatar for Learner010

i have a question that is this possible to create database application through c++ ? don't be confused in database application and file oriented application . if yes, then how can we create database application ?

Member Avatar for sidy
0
208
Member Avatar for coiseng

Hi all, I need some help regarding dynamic vector. Shape2DLink.cpp void Shape2DLink::InputSensor() { string shape,type; cout<<endl<<"\n"<<"[ Input sensor data ]"<<endl; cout << "Please enter name of shape: " << endl; cin >> shape; shape2D.setName(shape); cout << "Please enter special type : " << endl; cin >> type; shape2D.setWarpSpace(type); if(shape == …

Member Avatar for Moschops
0
475
Member Avatar for _Devower

Hello, I've searched around and found similar threads to my question, but haven't really found something that has helped this concept click. I'm trying to create 4x4 array that holds 8 pairs of numbers in randomly generated spaces. For example, the array: 1 1 2 2 3 3 4 4 …

Member Avatar for tinstaafl
0
2K
Member Avatar for Tewhano

This is not a problem that needs to be solved but a question to understand C++ code better. I have an assignment that has a class to get a date input where the validation for leap year is a member of. I found many examples online and one stands out …

Member Avatar for Tewhano
0
194
Member Avatar for Kyle777w

Hello, I've got a question about a project in my operating systems class. The task was to create a program that lets the user choose a variety of cpu scheduling algorithms and simulates them with random data or data from a file. I've already done it for first come first …

0
310
Member Avatar for Landoro

Hello guys and gals :) I admit I don't know whether there is a way to create a dynamic array of objects. I have a task to read a file with the structure: body_id x_low x_high y_low y_high z_low z_high body_id x_low x_high y_low y_high z_low z_high body_id x_low x_high …

Member Avatar for Moschops
0
462
Member Avatar for Girija_1

I have an issue with my code ... my below code is createing databases(database here is a kd tree) and indexing one image per database. i have two classes LastDatabaseTndexingPolicy and another forwardingDatabaseaccessor.cpp . I am calling the GetDatabaseToAccess() function from forwardingDatabaseAccessor.cpp class .GetDatabaseToAccess() function is present in LastDatabaseTndexingPolicy class …

Member Avatar for mike_2000_17
0
131
Member Avatar for coiseng

I'm just curious why my application actually crashes after it compute the area of a cross. I output is correct but it crashes after it calculation is done. cross.cpp void Cross::setCrossCord() { for (int i=0; i<=12; i++) { cout << "Please enter x-ordinate of pt " << i+1 << ": …

Member Avatar for kal_crazy
0
451
Member Avatar for umairs007

Write A Function called '**Seperator**' in C++ language which print 15 *s in a single line. Write Another Function named **"Multiple"** that takes an integer as an argument and prints its multiple up to ten terms, seperated by spaces,in a single line . Write A C++ Program which takes an …

Member Avatar for rubberman
-2
149
Member Avatar for Learner010

after getting bored with turbo c++ ide , now i have installed codelight ide for c++ and i don't know how to use it. well , i have done following created a workspace named "hello_world" created a project named "hello" while creating a project i was asked to give a …

Member Avatar for rubberman
0
129
Member Avatar for GillBates

hello all I'm trying to write a program that returns us [U]majority element[/U]. [I]An array is said to have a majority element if more than half of its entries are the same - [I]>(size of the array)/2[/I].[/I] It wouldn't be a problem if i had no conditions, but i have …

Member Avatar for kal_crazy
1
3K
Member Avatar for Richard_10

I am using the 3 files of code from the C++ book Chapter 11 and 11.8 Case Study:A Date Class with both cpp files and header file my questoion is how do i (add overloaded operator for "--" (pre and post), "-=", and ">>". For ">>", user expected to type …

Member Avatar for mike_2000_17
0
285
Member Avatar for shifa.abbasi
Member Avatar for Ancient Dragon
0
144
Member Avatar for TheDude11

So I need help creating a RPG program for my class. Below I posted what is needed...Any help is greatly appericated!! ***Unit 13 Graded Programming Assignment - RPG Game*** You are to create an RPG for your programming assignment. This program: needs to use at least one vector needs to …

Member Avatar for proctree
0
177
Member Avatar for cambalinho

by some reason the TextOut() function don't show me the text:( but see these code: #include <iostream> #include <string.h> #include <windows.h> using namespace std; int main() { HDC a=GetDC(GetForegroundWindow()); cout << GetLastError();//i get 0(no errors) Rectangle(a,3,4,3+80,4+20);//the rectangule is showed TextOut(a,10,10,"hello world",strlen("hello world")); cout << GetLastError();//i get 0(no errors) cin.get(); } …

Member Avatar for cambalinho
0
344
Member Avatar for passant.elwasimy

2. Write a function that takes an an MxN matrix such that if an element in this input matrix is 0, its entire row and column is set to 0. void changeMatrix(int *Mat[],int M, int N)

Member Avatar for ddanbe
0
67
Member Avatar for Swirly

I am trying to create Dijkstra's algorithm for a weighted graph, and have a flaw, I believe, in the implementation of the basic algorithm. It only visits the nearest nodes, checks the edges, but nothing else. Right now, I'm afraid I'm too close to this to see what's going on. …

Member Avatar for kal_crazy
0
279
Member Avatar for TheNewKid

Hey everyone, I am working on a win32 project right now and I have a few buttons that I wanted to change how they look so I gave them the BS_OWNERDRAW property and drew them myself. Now sense I am using ownerdraw there is no visual indication of when someoone …

Member Avatar for tinstaafl
0
288
Member Avatar for manel1989

hi all! i have to send a whole vector as a parameter from a code java (eclipse) to a c++ code(VS2010)i have some quations about that: 1. how can i send the whole vector in once? i already know how to send it element by element so i want to …

0
95
Member Avatar for cambalinho

i have 1 class Multithread, but seems that i have some errors:( #include <process.h> #include <string> using namespace std; class MultiThread { private: void * b; public: void ParameterList(void *c) { b=c; } void Thread(unsigned (__stdcall*) (void *) ) { _beginthreadex(NULL, 0, (__stdcall*) (void *) , b, 0, NULL); } …

Member Avatar for cambalinho
0
460
Member Avatar for DawnofanewEra

Why are some algorithm to solve TSP using dynamic programming can solve up to 10 cities while some can go beyond that...i.e. 10, 100 or more..!! What is the factor that determines the capability of the algortihm to solve more than 10 or less..??

Member Avatar for tinstaafl
0
1K
Member Avatar for priyanka.choudhary.90038

Hi, I do have doubt regarding const declaration in copy constructor. Can anyone let me know why do we need const reference in copy constructor, as we already know reference itself is const pointer.So why we should use const as a prefix in copy constructor. Regards, Mohan

Member Avatar for deceptikon
0
1K
Member Avatar for Vasthor

http://s8.postimg.org/zbfc0h92t/New_Bitmap_Image.png 'contents' can't be initialized whatever I did, thus I can't declare the type in this class class Window_mgr { public: // location ID for each screen on the window typedef std::vector<Screen>::size_type ScreenIndex; // reset the Screen at the given position to all blanks void clear(ScreenIndex); private: std::vector<Screen> screens{ Screen …

Member Avatar for tinstaafl
0
294
Member Avatar for cambalinho

can anyone explain to me what is: 'T', 'L', 'wchar_t', 'LPCWSTR' and 'LPCTSTR'? how can i convert strings\char* to these types? (i understand these isn't a tutorial, but i realy need these introdution) or you can give me just a nice link.

Member Avatar for cambalinho
0
142
Member Avatar for Lee_2

This may be a simple error but however. I was running my simple programs as normal and then when i went back to the program later to copy some code there was an error message highlighted underneath the first brace of my main() function. The error states - error: first …

Member Avatar for tinstaafl
0
2K
Member Avatar for saurav2007

#include<iostream> using namespace std; int &fun() { static int x = 10; return x; } int main() { fun() = 30; cout << fun(); return 0; } Output is 30 why not 10? please explain me the concept of Lvalue.. Thank you in advanvce.

Member Avatar for Ancient Dragon
0
278
Member Avatar for kelvin.njuguna

ou have been tasked to write a program that takes two complex number and return theie sum.However the + operator will not worl with complex numbers and you figure you need to verload the + and the assignment opeartor=.Ypu have come across the program (http://wwww.cprogramming.com/tutorial/operator_overloading.html) implement it and the client …

Member Avatar for Schol-R-LEA
0
295
Member Avatar for tbuchli

Create a check digit that is the remainder of the account number when it is divided by 5. This digit should be added to the end of the 4 digit account number. Account #12344 #include <cstdlib> // Standard C library... #include <iostream> // Contains cout, cin objects... using namespace std; …

Member Avatar for tbuchli
0
466
Member Avatar for jennifer.gregoryboswell

I need help with: *the code for y/n and entering a 0 or 10. * and how do I switch from lowest to highest to highest to lowest? Problem: Set up a grading program. The program should allow the user to enter grades from the keyboard until a 0 is …

Member Avatar for Ancient Dragon
0
173
Member Avatar for Suzie999

I found myself needing a threadsafe global variable to indicate when a thread is complete. Quickly discovered `std::atomic<type> var(val);` only to find it has no support in my IDE. Can anyone offer an alternative? I have an operation that needs to be carried out which takes some time, I cannot …

Member Avatar for rubberman
0
726

The End.