51,593 Topics

Member Avatar for
Member Avatar for v3ga

Hi everyone just started Daniweb! I have been using devcpp for some time.I am trying to make a switch from DevCpp to Visual Studio but find the latter confusing having so many options. Recently, I did a console application that will accept a word from user and prints its anagrams. …

Member Avatar for v3ga
0
276
Member Avatar for reddit

I am trying to make an 8x8 board with an array. The only problem I run into is making a box or square that will be placed into that array. for instance: @@@@@ @@@@@ @@@@@ @@@@@ @@@@@ @@@@@ @@@@@ @@@@@ @@@@@ @@@@@ @@@@@ @@@@@ @@@@@ @@@@@ @@@@@ @@@@@ @@@@@ @@@@@ …

Member Avatar for xfbs
0
125
Member Avatar for Vasthor

this code is for bring an output of "Hello, [name]!" with frame on its outside. [CODE]//ask for a person's name, and generated a frame greeting. #include <iostream> #include <string> // say what standard-library names we use using std::cin; using std::endl; using std::cout; using std::string; int main() { // ask for …

Member Avatar for Vasthor
0
458
Member Avatar for addision

First let me start by saying that I hope I wrapped my code properly. Next, my instructor sent us some code using a class and instructed us to add to it and make it so that we can display a checking account balance from a simple three line text file, …

Member Avatar for addision
0
139
Member Avatar for anushabit

Write a function which accepts a sentence as input parameter. Each word in that sentence is to b reversed (remember: not the whole sentence to b reversed, each word should b reversed). Space should b there between each word. Return the sentence with reversed words to main function and produce …

Member Avatar for mrnutty
0
94
Member Avatar for daldrome

Hey guys, I need to print out character symbols for this program. I need to print 2 different shapes of symbols. For the first shape, I have to print out a triangle, represented by the "*" in the nested for loop. I need to print out a square shape using …

Member Avatar for daldrome
0
198
Member Avatar for hardknock

Hello I have hit a wall with this issue, been at it for a few hours now and it is bewildering to me to say the least With that being said, the below code is giving me some erroneous answer during the execution. The user enters a number from the …

Member Avatar for hardknock
0
167
Member Avatar for dakerao

How do i constantly keep checking for specific characters in a text file till there are no more specific characters left. this way i can keep displaying text file logos on my application until there are none left in the text file being searched by c++ :) i did have …

Member Avatar for Lerner
0
200
Member Avatar for C++newbie chick

Hello, as you can tell from my username I'm completely new at C++ and have no idea how to write a function that won't chuck up any errors! What I'm trying to do is to compare an inputted student's ID number to ones already stored in my current array and …

Member Avatar for C++newbie chick
0
325
Member Avatar for plumsauce5

Write a program that will ask the user for the name of an item, the part number of the item, the cost of the item and the quantity of the item. The program will then calculate the total cost of the item. The program will also keep track of the …

Member Avatar for Stazloz
0
117
Member Avatar for tucker001
Member Avatar for Destluck

Alright to star off let me say sorry for my english typos. This question is not for a homework and in no way related to school. Im in 3d conception. But looking to get a program for personal use. I have a project i want to work on and need …

Member Avatar for raptr_dflo
0
153
Member Avatar for mc3330418

I have this project that takes a team name, how many members are on a team and the individual times. I need to output the teamname and times (in seconds) and then the total time of each team. I'm having trouble adding the total team times. [CODE]while(infile.peek() !=EOF) { getline …

Member Avatar for Narue
0
120
Member Avatar for wfws

I'm working on a school C++ program, and its my first that uses classes and objects. Its great fun, and I'm almost done. I have a problem with the search function, which involves several pieces of code- the .h files, the .cpp implementation file, and the main code file. If …

Member Avatar for gusano79
0
100
Member Avatar for sciwizeh

Hello all, working on an assignment for a class and I'm encountering something strange. After I'm getting a bad memory allocation exception upon exiting my program. After debugging the problem it appears to be a result of trying to make vector with negative length. The program runs fine until it …

0
89
Member Avatar for PixelExchange

I have a program which consists of two windows (hWnd, and picturewind). I would like to write code which takes an action every time a person clicks inside of the second window (picturewind) but not when the person clicks in the first window (hWnd). Can anyone tell me how I …

Member Avatar for PixelExchange
0
153
Member Avatar for circles

Hi all, 2nd week programming and face first into the wall again haha. As always I appreciate any advice or critique. I have a small c++ program that reads through log files from a program and scans for errors. For the most part it works really well but I'm trying …

Member Avatar for WaltP
0
192
Member Avatar for jhudielpeco

Please repair my loop. [CODE]#include <iostream> using namespace std; int main(){ int size; cout << "How large a triangle do you want? "; cin >> size; for (int r = 0; r < size; r++) { for (int c = 1; c <= size; c++) { if (c <= r) …

Member Avatar for WaltP
0
137
Member Avatar for BoBok2002

Hi, I have drawn a human face using simple shapes such as big circle for the face, little circles for the eyes, lines for eyebrows and triangle for the nose. I have been asked to create a template for various expressions of the face (fear, happiness, disgust, etc). Once I'm …

Member Avatar for BoBok2002
0
453
Member Avatar for ktsangop

Hi there! I would like a little help regarding the following code. The following code will wait for a non-blocking socket connection, and then wait to receive a certain packet. When the packet arrives, it will do something and then close connection and reinitialize it in order to be able …

Member Avatar for ktsangop
0
391
Member Avatar for basharg

Hello guys, I need some help with a program that finds all the prime numbers from 2 to 10000,here is what I have so far [CODE] #include <iostream> using namespace std; bool prime(int n ); void main () { int n,b; b=0; for (n=2;n<=10000;n++) prime (n); if () { cout<<n<<endl; …

Member Avatar for basharg
1
135
Member Avatar for Tom Gunn

CSV is more than just comma delimited fields. There are quoting and white space rules too. This is a short function as an example of a complete way to read CSV records line by line.

Member Avatar for moonlight01
2
371
Member Avatar for ayanbizz

I am trying to use Minipar parser.hence i downloaded it from the following link [url]http://webdocs.cs.ualberta.ca/~lindek/minipar.htm[/url] then I created an environment variable MINIPATH as was directed in the "Readme" file.But when i tried to run it through devc++ numerous errors occurred.the log file is as follows F:\pdemo\pdemo.cpp:20:19: ptree.h: No such file …

0
63
Member Avatar for infantheartlyje

Hi i could not specific Record from my binary file. This is the method to list out all records. [code] int student :: showall(fstream &fp) { student rec; fp.seekg(0,ios::beg); int i=0; cout<<"Position\tRoll No\t\tName\tBalance"<<endl; while(fp.read((char*)&rec,sizeof rec)) { cout<<i*sizeof rec<<"\t"; rec.show(); i++; } } [/code] While running this i got the below …

0
104
Member Avatar for carolinatech

Hey everyone, I'm need help with a problem I'm working on. I am trying to write a code that will tell how many coins are in the amount of change from 0 to 99. My algorithm is: Get total value of change Set value of quarters to q=.25 Set value …

Member Avatar for Stazloz
0
130
Member Avatar for allynm

Hello all, I recently installed MinGW on my XP Pro box (SP 3). When I click on the shell icon, the resulting behavior of the MinGW shell console window is incorrect. Initially, the console opens up as it should, complete with frame and scroll bars, but after about 5 seconds, …

Member Avatar for Stazloz
0
149
Member Avatar for Himajin Breaker

Is it possible to create a dynamic-sized array of structures within a structure? To provide some info, I want to read some student info off an input file, which includes some miscellaneous information, subject codes and corresponding marks. The number of subjects taken is also provided as a number in …

Member Avatar for Himajin Breaker
0
178
Member Avatar for Stazloz

I am writing a recursive function to return an integer after converting a string. I am very close. This was already quite the brain teaser, and recursion is not my cup of tea. Perhaps somebody can help with this small little problem I am having. The last thing I need …

Member Avatar for Stazloz
0
3K
Member Avatar for linhj

Hi all, I am doing the assignment as below. It is nothing wrong but just I think I complied c code and c++ code in the program. Now I would like to change it to work under c complier, but just dont know which part is wrong. Can anyone of …

Member Avatar for Panathinaikos22
0
257
Member Avatar for Duece_68

Hi guys, I've developed an application using C++ and this app uses a C# dll which is registered as a COM object. Now it works on the computer I developed it on. But it doesnt seem to work on another computer even though I registered the C# dll it needs. …

Member Avatar for Ancient Dragon
0
46
Member Avatar for optimus_prime_1

please install this C++ software and according to image i am getting few errors will some one help me solve this problem ? software link : http://www.ziddu.com/download/17082595/turboc.zip.html image link : http://www.ziddu.com/download/17082611/untitled.JPG.html thank you ....................

Member Avatar for Stazloz
0
1K
Member Avatar for Howdydoody

I'm writing an alphabet cipher that ciphers at random. It looks like it should work when I'm debugging it but when I look at the cipher key it comes out with duplicate letters like some of them weren't switched during the for loop. Any help is much appreciated. WasSwapped is …

Member Avatar for Howdydoody
0
151
Member Avatar for Interista

Hi i have about 5 types of strings having information in each string i need to transfer them into a binarytree so i need them in one node only i cant work out what i have to do.. every time i add a string it adds a node i want …

Member Avatar for rubberman
0
103
Member Avatar for jenbrandau341

Hello, I am new to C++ and very lost. I have attempted this program but my output displays file was unable to open. I am not sure I am even on the right track. Here is my project: Write a program that reads strings from a file into a vector. …

Member Avatar for jenbrandau341
0
111
Member Avatar for wfws

I'm working on a lab for my C++ class that is the first to use classes and objects. It requires a search function that lists tasks found for a target course. I can't get the search function to work. Here is the relevant code: from main source code: [CODE] void …

Member Avatar for MonsieurPointer
0
168
Member Avatar for Nasas

Can u help me guys. I have problem of calling function from class and overloading. When I'm trying to print short int type number, the program brakes down. No errors are shown which tell me whats wrong. [CODE]#include <cstdlib> #include <iostream> using namespace std; int i=0, j=0, zero_fill, l=0; class …

Member Avatar for Nasas
0
117
Member Avatar for glut

How would I make a file with Unicode characters in it? I don't know why this is so difficult to do, in any other language, you don't even have to specify that it's Unicode. This is what I have [CODE] #include <iostream> #include <fstream> using namespace std; int wmain() { …

Member Avatar for mazzica1
0
60
Member Avatar for Aghtar

Hey guys, now I have an assignment to create code that will ask for a number and then calculate the factorial of it with a for loop in a separate function and return the value to main.. Here is my code, I think it looks pretty good, but when I …

Member Avatar for StuXYZ
0
167
Member Avatar for nchy13

my insert function of redblack tree is working good for input checks listed as comments in main() say for 10 to 20 numbers which has included all types of color changes and rotations.. i am providing input of 1000 numbers to be inserted from input file "in 0" attached. i …

0
60
Member Avatar for Zssffssz

Ok this comes as two questions: what is the best variable for storing bianary data and how would I send That through a XOR gate? When I searched it didn't really do anything because XOR is a binary operator. I remember how to open o file in binary form from …

Member Avatar for mzimmers
0
121
Member Avatar for C++newbie chick

Hello guys, I'm trying to make it so that the user can opt to change student's course code or credit points (they can choose to change neither, either or both) in case 5 of my main switch statement. The problem is, the loop doesn't end after you choose to do …

Member Avatar for Ancient Dragon
0
318
Member Avatar for carolinatech

Hello everyone, I'm new to C++ and I have two assignments that I to work on. The first how do I write an algorithm that will search for the smallest, largest, and average out five random numbers. This is what I have so far for my algorithm: 1. Get value …

Member Avatar for Moschops
0
123
Member Avatar for ishaan3731

i am doing a project on student information system using file handling...i made my own project but it didnt work....i read many books but actually the main problem is that i lack logic.....i have found from the net this project but the output on the notepad file is giving unusual …

Member Avatar for ishaan3731
0
361
Member Avatar for Interista

Hi friends im trying to get my menu working but i just cant seem to get it working ... these are my 3 errors 9 " In file included from main.cpp" 47 " no matching function for call to `Menu::Menu(const char[7])' " 49 "std::string' has no member named 'add' " …

Member Avatar for Interista
0
129
Member Avatar for glut

What is cout? It's a variable, yet it can print stuff on the screen. Also, << (Left Shift Operator) isn't like the one for the variable cout. How does cout work? cout isn't even a macro / #define.

Member Avatar for vidit_X
0
148
Member Avatar for Zssffssz

Ok pretty simple: How to make internal speaker beep on Linux. For personal use does not need to be portable. I know I have an internal speaker... BIOS loves that thing...

Member Avatar for Zssffssz
0
168
Member Avatar for VengefulToast

Hey forum, our professor assigned us a program we have to write in assembly language and I would love to have help on it. [QUOTE]Write an upper-to-lower case and lower-to-upper case conversion program. When the user inputs a letter, your program should convert it to upper case if it is …

Member Avatar for D33wakar
0
581
Member Avatar for yurigagarin

Hi all, I have this code here and I like to save all the messages into 1 text file name contimer.txt. I've tried to do [CODE]FILE *output fopen_s(output,"comtimer.txt", "ww");[/CODE] right before the function Timer 1 and change every "printf" function into fprint_s(f, "Message", variables) but it does not help. Could …

Member Avatar for yurigagarin
0
330
Member Avatar for Interista

Hi im trying to get this to compile im try to make a menu this is my code but it wont work [code] //main.cpp #include <iostream> #include "Menu.h" using namespace std; int main(){ { SportsClothingMenu(); } system("pause"); return 0; } [/code] [code] //Menu.h #ifndef H_MENU #define H_MENU #include <iostream> #include …

Member Avatar for Interista
0
130
Member Avatar for aramil daern

hi everyone. I just switched over from a linux os to a mac osx. I have seen multiple suggestions on how to compile c++ but it won't work for me I have x code what do I do?

Member Avatar for rubberman
0
63

The End.